1
Hello! I am reading and studying about C++ in the book " C++ How to Program 5th edition ". There is a question in pg 97. Question 2.28 which I cannot accomplish, being it:
Write a program that inserts a five-digit integer, separates the integer into its individual digits and prints the separate digits each other for three spaces each. [Tip: Use integer division operators and module. ] For example, if the user type 42339, the program must print: 4 2 3 3 9.
From what I understand, I must do:
#include <iostream>
using namespace std;
int main () {
int x ;
cin >> x; // Digitar cinco números
// eu não faço ideia como separar estes números?
// alguém pede me ajudar?
return 0;
}