You should be setting reverse
back to 0 for each new n
while ( n <= 999)
{
reverse = 0; # <== otherwise you are using old value in reverse
temp = n;
while(temp!=0)
solved Palindromic numbers, code not working [closed]
You should be setting reverse
back to 0 for each new n
while ( n <= 999)
{
reverse = 0; # <== otherwise you are using old value in reverse
temp = n;
while(temp!=0)
solved Palindromic numbers, code not working [closed]