Submission

Status:

-----

Subtask/Task Score:

0/100

Score: 0

User: Phoom

Problemset: คำนำหน้าชื่อ

Language: cpp

Time: 0.002 second

Submitted On: 2025-11-10 20:50:58

#include <bits/stdc++.h>
using namespace std;

int main() {
    string n;
    int g;
    int a;
    int m;
    string t;
    cin >> n >> g >> a >> m;

    if (g == 1;a < 15) {
        t = "Master";
    }
    else if (g == 1;a >= 15) {
        t = "Mr.";
    }
    else if (g == 0;m == 0) {
        t = "Miss";
    }
    else if (g == 0;m == 1) {
        t = "Mrs.";
    }
    cout << t << " " << n;
}