234702026-01-23 15:32:17Firesloth28AI rizikócpp17Accepted 100/1001ms508 KiB
#include <bits/stdc++.h>
using namespace std;

void solve() {
    int a, b;
    cin >> a >> b;

    int drawPoints = a * 2 / 3 + 1;

    if (b == drawPoints) {
        cout << "draw" << endl;
    }
    else if (b < drawPoints) {
        cout << "tommaso" << endl;
    }
    else {
        cout << "filippo" << endl;
    }
}

int main() {
	int t;
    cin >> t;

    while (t--) {
        solve();
    }
}
SubtaskSumTestVerdictTimeMemory
subtask10/0
1Accepted1ms316 KiB
subtask230/30
2Accepted1ms316 KiB
3Accepted1ms316 KiB
subtask330/30
4Accepted1ms316 KiB
5Accepted1ms316 KiB
6Accepted1ms316 KiB
7Accepted1ms316 KiB
subtask440/40
8Accepted1ms508 KiB
9Accepted1ms316 KiB
10Accepted1ms316 KiB
11Accepted1ms316 KiB
12Accepted1ms316 KiB
13Accepted1ms500 KiB
14Accepted1ms316 KiB