Advertisement
Nofxthepirate

Exercise 2.17

Jan 23rd, 2018
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.29 KB | None | 0 0
  1. //Exercise 2.17
  2. //This program displays "1 2 3 4" in three different ways
  3. #include <iostream>
  4. using namespace std;
  5.  
  6. int main(){
  7.     cout << "1 2 3 4" << endl;
  8.     cout << "1 " << "2 " << "3 " << "4" << endl;
  9.     cout << "1 ";
  10.     cout << "2 ";
  11.     cout << "3 ";
  12.     cout << "4" << endl;
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement