結果
| 問題 |
No.481 1から10
|
| コンテスト | |
| ユーザー |
Kakisuke
|
| 提出日時 | 2018-12-17 20:32:37 |
| 言語 | C90 (gcc 12.3.0) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 275 bytes |
| コンパイル時間 | 114 ms |
| コンパイル使用メモリ | 21,120 KB |
| 実行使用メモリ | 6,944 KB |
| 最終ジャッジ日時 | 2024-09-25 07:37:32 |
| 合計ジャッジ時間 | 2,282 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | RE * 2 |
| other | RE * 8 |
コンパイルメッセージ
main.c: In function ‘main’:
main.c:7:20: warning: format ‘%d’ expects argument of type ‘int *’, but argument 2 has type ‘int’ [-Wformat=]
7 | scanf("%*s%d",b[i]);
| ~^ ~~~~
| | |
| | int
| int *
main.c:7:9: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
7 | scanf("%*s%d",b[i]);
| ^~~~~~~~~~~~~~~~~~~
ソースコード
#include<stdio.h>
int main()
{
int a[]={1,2,3,4,5,6,7,8,9,10};
int b[9],i;
for(i=0;i<9;i++){
scanf("%*s%d",b[i]);
}
i=0;
while(1){
if(a[i]!=b[i]){
break;
}
i++;
}
printf("%d\n",a[i]);
return 0;
}
Kakisuke