結果
| 問題 |
No.512 魔法少女の追いかけっこ
|
| コンテスト | |
| ユーザー |
Haijinn
|
| 提出日時 | 2017-05-06 14:04:38 |
| 言語 | C90 (gcc 12.3.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 240 bytes |
| コンパイル時間 | 438 ms |
| コンパイル使用メモリ | 20,480 KB |
| 実行使用メモリ | 6,948 KB |
| 最終ジャッジ日時 | 2024-06-27 06:19:12 |
| 合計ジャッジ時間 | 1,668 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 26 WA * 27 |
コンパイルメッセージ
main.c: In function ‘main’:
main.c:9:1: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
9 | scanf("%d%d",&x,&y);
| ^~~~~~~~~~~~~~~~~~~
main.c:10:1: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
10 | scanf("%d",&n);
| ^~~~~~~~~~~~~~
main.c:12:9: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
12 | scanf("%d",&a[i]);
| ^~~~~~~~~~~~~~~~~
ソースコード
#include <stdio.h>
#include<stdlib.h>
int main(void)
{
int x,y;
int n;
int a[100];
int i;
scanf("%d%d",&x,&y);
scanf("%d",&n);
for(i=0;i<n;i++){
scanf("%d",&a[i]);
}
if(y-x<=10){
printf("YES\n");
}else{
printf("NO\n");
}
return 0;
}
Haijinn