[TIB] Re: [OT] C++ help


[Next][Index][Thread]

[TIB] Re: [OT] C++ help




I Don't know much c++ but if it has some operations that allow you to take
one digit of a number or string and seperate it you could take digits from
the end and then store it into a new variable then append the rest of the
digits until you have rewritten the number backwards and then compare it to
the original and if they are equal then it is.

> I need some help w/ a program for c++, i need to take a six-digit number
> entered by the user that could be a possible palindrome(a six digit
> number that reads the same front and back, i.e. 123321, 456654), the
> program has to determine if the number is a palindrome or not, and all i
> can use is if/else statements and the switch statement and logical
> operators, any ideas?
>
> Chris