結果
問題 |
No.2773 Wake up Record 1
|
ユーザー |
![]() |
提出日時 | 2025-03-17 13:24:40 |
言語 | C (gcc 13.3.0) |
結果 |
RE
|
実行時間 | - |
コード長 | 255 bytes |
コンパイル時間 | 261 ms |
コンパイル使用メモリ | 24,704 KB |
実行使用メモリ | 7,328 KB |
最終ジャッジ日時 | 2025-03-17 13:24:45 |
合計ジャッジ時間 | 4,372 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | WA * 1 RE * 2 |
other | WA * 5 RE * 17 |
コンパイルメッセージ
main.c: In function ‘main’: main.c:4:9: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 4 | scanf("%d" , &n); | ^~~~~~~~~~~~~~~~ main.c:6:9: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 6 | scanf("%s",sleeptime); | ^~~~~~~~~~~~~~~~~~~~~
ソースコード
#include <stdio.h> void main(void){ int n = 0; scanf("%d" , &n); char sleeptime[1000000] = "a"; scanf("%s",sleeptime); int i = 1; while(sleeptime[i] != '\n'){ if(sleeptime[i] == 'o' && sleeptime[i-1] == 'x'){ printf("%d ", i+1); } i++; } }