+ 2
what's the ((x%10)/5) mean
if the roop has 20 numbersļ¼it will println like this 00000111110000011111, for(i=0ļ¼i<20ļ¼i++)ļ½ system.out.print((x%10)/5)ļ¼ ļ½ Why is that? If I want to get three 0 followed by five 1, and then loop, how should i doļ¼like this 000111110001111100011111
2 Answers
+ 7
x%10 returns the remainder of x divided by 10.
Then, after computing x%10, we divide the value by 5.
0
????