Guest User

Untitled

a guest
Jan 21st, 2019
151
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.80 KB | None | 0 0
  1. // address.cpp
  2.  
  3. #include <iostream.h>
  4. #include "oostring.h"
  5.  
  6. int main()
  7. {
  8.   oostring name;
  9.   oostring address;
  10.   oostring city;
  11.   oostring state;
  12.   oostring zip;
  13.   oostring phone;
  14.  
  15.   cout << "Enter the following personal information:" << endl;
  16.   cout << "Name: ";
  17.   getline(cin, name);
  18.   cout << "Street Address: ";
  19.   getline(cin, address);
  20.   cout << "City: ";
  21.   getline(cin, city);
  22.   cout << "State: ";
  23.   getline(cin, state);
  24.   cout << "ZIP code (example: 79363-1151): ";
  25.   getline(cin, zip);
  26.   cout << "Phone number (example: 806-555-1000): ";
  27.   getline(cin, phone);
  28.  
  29.   cout << endl << "The information you entered follows:" << endl;
  30.   cout << name << endl;
  31.   cout << address << endl;
  32.   cout << city << ", " << state << "  " << zip << endl;
  33.   cout << phone << endl;
  34.  
  35.   return 0;
  36. }
Add Comment
Please, Sign In to add comment