100^100 | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

100^100

How to do it in c?? I want to check" how many digit in it?"

18th Jun 2019, 2:26 PM
BoltAction Gaming
BoltAction Gaming - avatar
6 Answers
+ 2
Thomas Williams, when the conversion takes place, the number will already be off due to overflow.
18th Jun 2019, 2:56 PM
HonFu
HonFu - avatar
+ 1
Other wise you get the length of 100 and add 100 to thag
18th Jun 2019, 2:43 PM
Trigger
Trigger - avatar
+ 1
The first one? That's because there are too many digits, right?
18th Jun 2019, 3:07 PM
Trigger
Trigger - avatar
+ 1
In python my second method will be len(str(num1)) + num2
18th Jun 2019, 3:08 PM
Trigger
Trigger - avatar
0
Convert it to a string and check the amount of characters in it.
18th Jun 2019, 2:40 PM
Trigger
Trigger - avatar
0
I know how to do it.. The way i mean.. But i dont know what int type i should use or what would be the string length? Or Even "%llu" shows 0..
18th Jun 2019, 3:28 PM
BoltAction Gaming
BoltAction Gaming - avatar