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

Python Program question

Create a program that will receive integer N and write the smallest integer 10**x that is greater than N.

29th Sep 2019, 8:49 AM
Ryan Saefulrochman
Ryan Saefulrochman - avatar
2 Answers
+ 1
Use integer division by 10 on N, count the number of times you have to do that until the result is 0. return 10**count.
29th Sep 2019, 9:48 AM
Thoq!
Thoq! - avatar
0
Thanks
29th Sep 2019, 10:09 AM
Ryan Saefulrochman
Ryan Saefulrochman - avatar