Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int aaa = 5055;
- int p1 = aaa % 10;
- int p2 = ((aaa - p1) % 100) / 10;
- int p3 = ((aaa - p2-p1) % 1000) / 100;
- int p4 = ((aaa - p3-p2-p1) % 10000) / 1000;
- cout << p1 << endl << p2 << endl << p3 << endl << p4;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement