Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <iostream>
- using namespace std;
- int main()
- {
- int age;
- cin >> age;
- string gender;
- cin >> gender;
- if (gender == "f")
- {
- if (age >= 16)
- {
- cout << "Ms.";
- }
- else
- {
- cout << "Miss";
- }
- }
- else
- {
- if (age >= 16)
- {
- cout << "Mr.";
- }
- else
- {
- cout << "Master";
- }
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement