結果
| 問題 | No.293 4>7の世界 |
| コンテスト | |
| ユーザー |
184
|
| 提出日時 | 2015-10-23 22:37:17 |
| 言語 | C++11 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 390 bytes |
| 記録 | |
| コンパイル時間 | 175 ms |
| コンパイル使用メモリ | 53,020 KB |
| 実行使用メモリ | 7,976 KB |
| 最終ジャッジ日時 | 2026-04-03 11:57:03 |
| 合計ジャッジ時間 | 936 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge4_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 WA * 1 |
| other | AC * 12 WA * 8 |
ソースコード
#include <cstdio>
#include <cstring>
#include <algorithm>
using namespace std;
//namaega184
int main(){
char a[100001],b[100001];scanf("%s%s",a,b);
int la=strlen(a),lb=strlen(b);
if(la<lb){a:printf("%s\n",b);return 0;}
else if(la>lb){b:printf("%s\n",a);return 0;}
else{
for(int i=0;i<la;i++){
if(a[i]<b[i])goto b;
else if(a[i]>b[i])goto a;
}
}
printf("-1\n");
return 0;
}
184