![]() |
| ||
| Can anyone figure out what is wrong in my program? I need to make a program to check if the entered number is palindrome or not i.e. if u take a number and reverse it it will be the same old number for example if u take 121..then if u reverse the number it will be 121 and so 121 is a palindrome number. i wrote a program to check if a number is palindrome or not but it is not working properly :cry: ...Can any1 plz tell me wat is wrong.. The program which I wrote is below:-
|
| ||
| Re: Can any1 figure out wat is wrong in my program!!PLZ!! >if(m==n) n is zero at this point, remember? Use a copy of n for your loop counter so that the original value is preserved. |
| ||
| Re: Can any1 figure out wat is wrong in my program!!PLZ!! Hey thanx a lot Narue...my program is working Perfectly now!! :cheesy: And once again Thanx a lot.... |
| ||
| Re: Can any1 figure out wat is wrong in my program!!PLZ!! Just a helpful hint here on the forum for you: Cn u plz not use chat spk here? Wat do u want 2 do that for? U got all d time in d world 2 make a post, so there's no need 2 uz chat spk n here. Please, for all of our eyes' sakes, spend about 30 seconds more on your post, and spell words in a non-lame fashion. kthxbye! :D |
| ||
| Re: Can anyone figure out what is wrong in my program? tx alx, i culdnt ha sd it b8ter mself |
| ||
| Re: Can anyone figure out what is wrong in my program? Your program is write up to if(m==n) in the above program n will become zero after the loop. So assign n value to any other variable,then compare with m. |
| ||
| Re: Can anyone figure out what is wrong in my program? Congratulations, muraliaa! It took you only four years to come up with the same answer as me. |
| ||
| Re: Can anyone figure out what is wrong in my program? 1 Attachment(s) This thread is so old, it saw the creation of the previous LHC :) |
| ||
| Re: Can anyone figure out what is wrong in my program? Quote:
|
| All times are GMT -4. The time now is 10:21 pm. |
Forum system based on vBulletin Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
©2003 - 2009 DaniWeb® LLC