What does the % in the line mean - if (x % 2 == 0) | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 3

What does the % in the line mean - if (x % 2 == 0)

Thanks

28th Apr 2017, 11:07 AM
Leo
Leo  - avatar
4 Answers
28th Apr 2017, 11:13 AM
Burey
Burey - avatar
+ 1
Thank you both :)
28th Apr 2017, 11:14 AM
Leo
Leo  - avatar
0
is the remainder after division is 0, then the condition is true
29th Apr 2017, 4:51 PM
pranav gupta
pranav gupta - avatar
0
what is the meaning oh i = i +1 in while loop??
30th Apr 2017, 9:58 AM
Mad Dy
Mad Dy - avatar