結果

問題 No.201 yukicoderじゃんけん
ユーザー Kaz_nl
提出日時 2017-09-02 22:07:05
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
AC  
実行時間 3 ms / 5,000 ms
コード長 368 bytes
コンパイル時間 491 ms
コンパイル使用メモリ 56,100 KB
実行使用メモリ 5,248 KB
最終ジャッジ日時 2024-11-06 18:37:46
合計ジャッジ時間 1,258 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 20
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <string>
using namespace std;

int main() {
  string sa, pa, xa, sb, pb, xb;
  cin >> sa >> pa >> xa >> sb >> pb >> xb;
  if (pa.length() > pb.length()) cout << sa << endl;
  else if (pa.length() < pb.length()) cout << sb << endl;
  else if (pa > pb) cout << sa << endl;
  else if (pa < pb) cout << sb << endl;
  else cout << -1 << endl;
}
0