/ SeriousOJ /

Record Detail

Wrong Answer


  
# Status Time Cost Memory Cost
#1 Wrong Answer 1ms 532.0 KiB
#2 Accepted 1ms 532.0 KiB
#3 Accepted 1ms 324.0 KiB
#4 Accepted 1ms 320.0 KiB
#5 Accepted 1ms 532.0 KiB
#6 Wrong Answer 1ms 504.0 KiB

Code

#include <iostream>
#include <string>
#include <unordered_map>

using namespace std;

int main() {
    string s;
    cin >> s;

    unordered_map<char, int> main; 
    for (char c : s) {
        main[c]++;
    }

    
    if (main['l'] >= 2 && main['e'] >= 2 && main['a'] >= 1 &&
        main['d'] >= 1 && main['i'] >= 2 && main['n'] >= 2 &&
        main['g'] >= 1 && main['u'] >= 1 && main['v'] >= 1 &&
        main['r'] >= 1 && main['s'] >= 1 && main['t'] >= 1 &&
        main['y'] >= 1) {
        cout << "Leading University" << endl;
    } else {
        cout << "Impossible" << endl;
    }

    return 0;
}

Information

Submit By
Type
Submission
Problem
P1024 Rearrange Character
Contest
Brain booster #2
Language
C++20 (G++ 13.2.0)
Submit At
2024-03-06 15:23:31
Judged At
2024-11-11 03:41:40
Judged By
Score
40
Total Time
1ms
Peak Memory
532.0 KiB