+ 1

How can I check if an integer ends with a zero?

So I'm talking about ages here. So the numbers are mostly like 35, 20 and so on. The program should recognize that the 20 ends with a 0 and 35 not. thanks in advance xx

19th Apr 2017, 8:48 AM
‎ɐısıօլɐ
‎ɐısıօլɐ - avatar
1 Odpowiedź
+ 4
if (x%10 == 0) {... }
19th Apr 2017, 8:51 AM
Jeth
Jeth - avatar