#include using namespace std; using ll = long long; template T smax(T & x, T y) { if (x < y) { x = y; return true; } return false; } template T smin(T & x, T y) { if (x > y) { x = y; return true; } return false; } const int mod = 998244353; int sum(int x, int y) { if (x + y >= mod) { return x + y - mod; } return x + y; } int diff(int x, int y) { if (x >= y) { return x - y; } return x - y + mod; } int mult(int x, int y) { return (int) ((x * 1LL * y) % mod); } int mypow(int x, int p) { int ans = 1; while (p > 0) { if ((p & 1) == 1) { ans = mult(ans, x); } x = mult(x, x); p >>= 1; } return ans; } int inv(int x) { return mypow(x, mod - 2); } template struct flow_graph { struct edge { int from; int to; cap_t cap; cap_t flow{}; bool ok(cap_t push) const { if constexpr (is_integral_v) { return flow + push <= cap; } return flow < cap; } }; static auto constexpr INF = numeric_limits::max(); int n; vector edges; vector> graph; vector d; explicit flow_graph(int n) : n(n), graph(n) {} void add_edge(int from, int to, cap_t cap) { auto i = (int) edges.size(); graph[from].push_back(i); edges.push_back({from, to, cap}); graph[to].push_back(i ^ 1); edges.push_back({to, from, 0}); } bool bfs(cap_t push, int s, int t) { d.assign(n, -1); d[s] = 0; vector q(n); q[0] = s; int qh = 0; int qt = 1; while (qh != qt) { auto v = q[qh++]; for (auto ei : graph[v]) { auto& e = edges[ei]; if (e.ok(push) && d[e.to] < 0) { d[e.to] = d[v] + 1; q[qt++] = e.to; } } } return d[t] >= 0; } flow_t max_flow(int s, int t, bool scale) { flow_t result = 0; for (int log = scale ? 30 : 0; log >= 0; --log) { while (bfs(1 << log, s, t)) { vector::iterator> ptr(n); for (int i = 0; i != n; ++i) { ptr[i] = graph[i].begin(); } auto dfs = [&](auto&& dfs, int v, cap_t cMin) -> cap_t { if (v == t) { return cMin; } for (; ptr[v] != graph[v].end(); ++ptr[v]) { auto ei = *ptr[v]; auto& e = edges[ei]; if (e.ok(1 << log) && d[e.to] == d[v] + 1) { auto pushed = dfs(dfs, e.to, min(cMin, e.cap - e.flow)); if (pushed) { e.flow += pushed; edges[ei ^ 1u].flow -= pushed; return pushed; } } } return 0; }; while (auto pushed = dfs(dfs, s, INF)) { result += pushed; } } } return result; } }; void solve() { int h1, d1, t1, h2, d2, t2; cin >> h1 >> d1 >> t1 >> h2 >> d2 >> t2; int time1 = ((h2 + d1 - 1) / d1 - 1) * t1; int time2 = ((h1 + d2 - 1) / d2 - 1) * t2; if (time1 < time2) { cout << "player one\n"; } else if (time1 > time2) { cout << "player two\n"; } else { cout << "draw\n"; } } int main() { ios::sync_with_stdio(false); cin.tie(nullptr); int t = 1; // cin >> t; while (t--) { solve(); } cerr << clock() * 1.0 / CLOCKS_PER_SEC << "\n"; return 0; }