QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#91026#5436. DRX vs. T1SaanteyeWA 2ms3328kbC++14639b2023-03-26 19:20:372023-03-26 19:20:39

Judging History

你现在查看的是最新测评结果

  • [2023-08-10 23:21:45]
  • System Update: QOJ starts to keep a history of the judgings of all the submissions.
  • [2023-03-26 19:20:39]
  • 评测
  • 测评结果:WA
  • 用时:2ms
  • 内存:3328kb
  • [2023-03-26 19:20:37]
  • 提交

answer

#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int,int> PII;
typedef unsigned long long ull;

void solve() {
    string s;
    cin >> s;
    int t = 0, d = 0;
    for(int i = 0; i < s.size(); i++) {
        if(s[i] == 'T') t += 1;
        if(s[i] == 'D') t += 1;
        if(t == 3) {
            cout << "T1";
            return ;
        }
        if(d == 3) {
            cout << "DRX";
            return ;
        }
    }
}

signed main() {
    ios::sync_with_stdio(false);
    cin.tie(0);
   
    int t = 1;
    //cin >> t;

    while(t--) solve();


    return 0;
}

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 2ms
memory: 3328kb

input:

TDTT?

output:

T1

result:

ok single line: 'T1'

Test #2:

score: -100
Wrong Answer
time: 2ms
memory: 3236kb

input:

DTDD?

output:

T1

result:

wrong answer 1st lines differ - expected: 'DRX', found: 'T1'