結果

問題 No.304 鍵(1)
ユーザー むらためむらため
提出日時 2018-12-18 12:02:18
言語 C
(gcc 12.3.0)
結果
AC  
実行時間 60 ms / 2,000 ms
コード長 214 bytes
コンパイル時間 551 ms
コンパイル使用メモリ 27,496 KB
実行使用メモリ 24,312 KB
平均クエリ数 309.17
最終ジャッジ日時 2023-09-24 02:03:10
合計ジャッジ時間 1,514 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 30 ms
24,204 KB
testcase_01 AC 28 ms
23,436 KB
testcase_02 AC 60 ms
23,388 KB
testcase_03 AC 29 ms
23,856 KB
testcase_04 AC 43 ms
23,412 KB
testcase_05 AC 28 ms
24,312 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
main.c: 関数 ‘main’ 内:
main.c:8:5: 警告: 関数 ‘getline’ の暗黙的な宣言です [-Wimplicit-function-declaration]
    8 |     getline(&str, &size, stdin);
      |     ^~~~~~~

ソースコード

diff #

#include <stdio.h>
char *str = NULL;
size_t size;
int main() {
  for (int i = 0; i < 1000; i++) {
    printf("%03d\n", i);
    fflush(stdout);
    getline(&str, &size, stdin);
    if (str[0] == 'u') return 0;
  }
}
0