QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#107110 | #5436. DRX vs. T1 | warner1129# | AC ✓ | 2ms | 3460kb | C++20 | 1.6kb | 2023-05-20 13:05:46 | 2023-05-20 13:05:47 |
Judging History
answer
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/pb_ds/hash_policy.hpp>
#include <ext/pb_ds/priority_queue.hpp>
using namespace std;
using namespace __gnu_pbds;
#ifdef LOCAL
void dbg() { cerr << '\n'; }
template<class T, class ...U> void dbg(T a, U ...b) { cerr << a << ' ', dbg(b...); }
template<class T> void org(T l, T r) { while (l != r) cerr << *l++ << ' '; cerr << '\n'; }
#define debug(args...) (dbg("(" + string(#args) + ") = (", args, ")"))
#define orange(args...) (cerr << "[" + string(#args) + ") = ", org(args))
#else
#pragma GCC optimize("O3,unroll-loops")
#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt")
#define debug(...) ((void)0)
#define orange(...) ((void)0)
#endif
template<class T> bool chmin(T &a, T b) { return b < a and (a = b, true); }
template<class T> bool chmax(T &a, T b) { return b > a and (a = b, true); }
#define all(v) begin(v), end(v)
#define rall(v) rbegin(v), rend(v)
#define ff first
#define ss second
typedef pair<int, int> pii;
typedef pair<long long, long long> pll;
typedef pair<double, double> pdd;
template<class T>
using BST = tree<T, null_type, less<T>, rb_tree_tag, tree_order_statistics_node_update>;
constexpr int INF = 1<<30;
constexpr long long mod = 998244353;
void solve() {
string S;
cin >> S;
int t = count(all(S), 'T');
if (t == 3) cout << "T1\n";
else cout << "DRX\n";
}
signed main() {
ios::sync_with_stdio(false), cin.tie(0), cout.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: 3308kb
input:
TDTT?
output:
T1
result:
ok single line: 'T1'
Test #2:
score: 0
Accepted
time: 2ms
memory: 3448kb
input:
DTDD?
output:
DRX
result:
ok single line: 'DRX'
Test #3:
score: 0
Accepted
time: 2ms
memory: 3408kb
input:
DDD??
output:
DRX
result:
ok single line: 'DRX'
Test #4:
score: 0
Accepted
time: 2ms
memory: 3316kb
input:
DDTD?
output:
DRX
result:
ok single line: 'DRX'
Test #5:
score: 0
Accepted
time: 2ms
memory: 3408kb
input:
DDTTD
output:
DRX
result:
ok single line: 'DRX'
Test #6:
score: 0
Accepted
time: 0ms
memory: 3460kb
input:
DDTTT
output:
T1
result:
ok single line: 'T1'
Test #7:
score: 0
Accepted
time: 0ms
memory: 3348kb
input:
DTDTD
output:
DRX
result:
ok single line: 'DRX'
Test #8:
score: 0
Accepted
time: 2ms
memory: 3348kb
input:
DTDTT
output:
T1
result:
ok single line: 'T1'
Test #9:
score: 0
Accepted
time: 1ms
memory: 3380kb
input:
DTTDD
output:
DRX
result:
ok single line: 'DRX'
Test #10:
score: 0
Accepted
time: 0ms
memory: 3348kb
input:
DTTDT
output:
T1
result:
ok single line: 'T1'
Test #11:
score: 0
Accepted
time: 2ms
memory: 3400kb
input:
DTTT?
output:
T1
result:
ok single line: 'T1'
Test #12:
score: 0
Accepted
time: 1ms
memory: 3416kb
input:
TDDD?
output:
DRX
result:
ok single line: 'DRX'
Test #13:
score: 0
Accepted
time: 1ms
memory: 3308kb
input:
TDDTD
output:
DRX
result:
ok single line: 'DRX'
Test #14:
score: 0
Accepted
time: 2ms
memory: 3348kb
input:
TDDTT
output:
T1
result:
ok single line: 'T1'
Test #15:
score: 0
Accepted
time: 0ms
memory: 3408kb
input:
TDTDD
output:
DRX
result:
ok single line: 'DRX'
Test #16:
score: 0
Accepted
time: 2ms
memory: 3384kb
input:
TDTDT
output:
T1
result:
ok single line: 'T1'
Test #17:
score: 0
Accepted
time: 2ms
memory: 3416kb
input:
TTDDD
output:
DRX
result:
ok single line: 'DRX'
Test #18:
score: 0
Accepted
time: 2ms
memory: 3348kb
input:
TTDDT
output:
T1
result:
ok single line: 'T1'
Test #19:
score: 0
Accepted
time: 2ms
memory: 3412kb
input:
TTDT?
output:
T1
result:
ok single line: 'T1'
Test #20:
score: 0
Accepted
time: 2ms
memory: 3416kb
input:
TTT??
output:
T1
result:
ok single line: 'T1'