+ 1

Sum of even number if (i%2=0) showing i=1 error

Sum of even numbers program showing variable 1 error in if condition?

13th Oct 2019, 2:26 PM
Ramya
2 odpowiedzi
+ 6
You should use "==" instead of "=". (i%2==0)
13th Oct 2019, 2:30 PM
Seb TheS
Seb TheS - avatar
+ 5
It would be easier if you added the code (i%2==0)
13th Oct 2019, 2:31 PM
Daniel (kabura)
Daniel (kabura) - avatar