[user02@FC4 Lesson07]$ cat -n twonbrs.cpp
1 #include <iostream>
2 using namespace std;
3
4 int main()
5 {
6 int first, second; // Numbers typed at the keyboard
7
8 cout << "Type two numbers and press Enter: ";
9 cin >> first >> second;
10 cout << "The numbers typed were " << first << " and " << second << endl;
11
12 return 0;
13 }
[user02@FC4 Lesson07]$ g++ -o twonbrs twonbrs.cpp[user02@FC4 Lesson07]$ ./twonbrs
Type two numbers and press Enter: 37 478
The numbers typed were 37 and 478
[user02@FC4 Lesson07]$ ./twonbrs
Type two numbers and press Enter: abc def
The numbers typed were 12480500 and 0
lesson_7_twonbrs.cpp, Rev. 3, Last changed on 2005-08-18 06:18, 293 page hits