結果
問題 |
No.201 yukicoderじゃんけん
|
ユーザー |
|
提出日時 | 2020-09-18 11:48:55 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 2 ms / 5,000 ms |
コード長 | 431 bytes |
コンパイル時間 | 1,695 ms |
コンパイル使用メモリ | 193,992 KB |
最終ジャッジ日時 | 2025-01-14 16:06:49 |
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 20 |
ソースコード
#include <bits/stdc++.h> using namespace std; string s1, s2, p1, p2, s; void input() { cin >> p1 >> s1 >> s >> p2 >> s2 >> s; } void solve() { string ans = "-1"; if (s1.size() > s2.size()) ans = p1; else if (s1.size() < s2.size()) ans = p2; else if (s1 > s2) ans = p1; else if (s1 < s2) ans = p2; cout << ans << endl; } int main() { ios::sync_with_stdio(false); cin.tie(0); input(); solve(); }