#include <iostream>
usingnamespace std;
int main()
{
int age;
int name;
int Lname;
cout << "Enter your name" << endl;
cin >> name;
cout << "Enter your last name" << endl;
cin >> Lname;
cout << "Enter your age" << endl;
cin >> age;
}
what im trying to do is get it to pause between cin entries, where as right now once i type my name it runs the rest of the code without allowing me to imput the rest of the information
You have given your "name" a type of int. Integers are numbers. When you type "Mason", the computer doesn't know what kind of number to make of that, and so it marks it as an error, and so all further attempts to read information are also errors and your program runs all the way to completion.
Use strings for textual information (like names), and ints for (integer) numbers.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
#include <iostream>
#include <string>
usingnamespace std;
int main()
{
int age;
string name;
string Lname;
cout << "Enter your name" << endl;
cin >> name;
cout << "Enter your last name" << endl;
cin >> Lname;
cout << "Enter your age" << endl;
cin >> age;
return 0;
}