rootiest revised this gist 2 months ago. Go to revision
1 file changed, 11 insertions
hello-world.cpp(file created)
| @@ -0,0 +1,11 @@ | |||
| 1 | + | #include <iostream> | |
| 2 | + | #include <string> | |
| 3 | + | using namespace std; | |
| 4 | + | ||
| 5 | + | int main() { | |
| 6 | + | string name; | |
| 7 | + | cout << "\nWhat is your name (first and last)? "; | |
| 8 | + | getline(cin, name); | |
| 9 | + | cout << "\nHello, " << name << endl; | |
| 10 | + | return 0; | |
| 11 | + | } | |
Newer
Older