0

How to print 12 digit number in C

I want to take a 12 digit number from user and diaplay on screen. But I don't want to use a string.

17th May 2021, 10:30 AM
Piyush A. Mulatkar
Piyush A. Mulatkar - avatar
3 Antworten
0
maybe, get number as string, x = first 6 digits y = last 6 digits cout<<x<<y;
17th May 2021, 10:51 AM
Bhavik Mahalle
Bhavik Mahalle - avatar
0
C-MOON thx... Also what is the limit of digits that we can store?
17th May 2021, 11:04 AM
Piyush A. Mulatkar
Piyush A. Mulatkar - avatar
0
The Stone #include <stdio.h> #include <limits.h> int main() { printf("%ld", LONG_MAX); return 0; } // OUTPUT: 9223372036854775807
17th May 2021, 11:32 AM
RKK
RKK - avatar