Submission
Status:
PPPPP
Subtask/Task Score:
100/100
Score: 100
User: Tjeez
Problemset: คำนำหน้าชื่อ
Language: cpp
Time: 0.004 second
Submitted On: 2026-10-09 01:04:56
#include <bits/stdc++.h>
using namespace std;
int main(){
string s;
getline(cin,s);
int g,m;
int a;
cin>>g>>a>>m;
if(g==1&&a>=15)cout<<"Mr. ";
else if (g==1&&a<15) cout<<"Master ";
else if(g==0&&a<15) cout<<"Miss ";
else if (g==0 && a>=15 && m==0) cout<<"Miss ";
else cout<<"Mrs. ";
cout<<s;
}