結果
| 問題 |
No.305 鍵(2)
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2015-12-04 00:15:56 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
AC
|
| 実行時間 | 27 ms / 2,000 ms |
| コード長 | 884 bytes |
| コンパイル時間 | 520 ms |
| コンパイル使用メモリ | 59,472 KB |
| 実行使用メモリ | 25,476 KB |
| 平均クエリ数 | 52.15 |
| 最終ジャッジ日時 | 2024-07-16 21:59:22 |
| 合計ジャッジ時間 | 1,812 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 13 |
ソースコード
#include <iostream>
#include <cstring>
#include <algorithm>
#include <limits.h>
#define REP(i,a,b) for(i=a;i<b;i++)
#define rep(i,n) REP(i,0,n)
using namespace std;
typedef long long ll;
typedef unsigned long long ull;
typedef long double ld;
/* ここからが本編 */
/* */
int int_pow(int x,int n) {
int res = 1;
while(n > 0) {
if(n&1) res = res * x;
x = x * x;
n >>= 1;
}
return res;
}
int main(void)
{
int test = 1;
int i,j,k,l;
int a,b,c,d;
char s[] = "0000000000";
char rep_s[15];
for(i=0;;i++) {
c = 0;
cout << s << endl;
cin >> a >> rep_s;
if(rep_s[0] == 'u') exit(0);
for(j=1;j<10;j++) {
s[i]++;
cout << s << endl;
cin >> b >> rep_s;
if(rep_s[0] == 'u') exit(0);
if(a < b) break;
else if(a > b) {
s[i] = '0';
break;
}
}
}
return 0;
}