Look here for a complete description of the problem. Your code should follow the coding standards,
good names, spacing, easy on the eyes...etc. Make sure you handle all test case and
boundaries. Good Luck, and happy coding. Although this is a C++ forum, it would be nice to
see some different language used to solve this, but not necessary though.
mrnutty
761
Senior Poster
Recommended Answers
Jump to PostHi
I have just got this solution:#include <iostream> using namespace std; unsigned long int reversi(unsigned long int n) {unsigned long int r=0; unsigned short f; for(;n;n/=10)if(((f=n%10)!=0)||(r!=0))r=10*r+f;return r;} int main(){ unsigned long int x, y; cout <<"1st number: "; cin>>x; cout <<"2nd number: "; cin>>y; cout <<"Reversed …
All 2 Replies
1stDAN
iamthwee
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.