Submission

Status:

PPPPPPPPPP

Subtask/Task Score:

100/100

Score: 100

User: exoworldgd

Problemset: ตัวอักษรตัวแรกในคำ

Language: cpp

Time: 0.002 second

Submitted On: 2025-05-29 19:27:33

#include <bits/stdc++.h>
using namespace std;
int main(void) {
    string a;
    cin >> a;
    map<char,int> freq;
    for (char c : a) freq[c]++;
    vector<char> ch;
    for (auto [l,r] : freq) if (r == 1) ch.push_back(l);
    sort(ch.begin(),ch.end());
    cout << ch[0];
}