結果
問題 | No.687 E869120 and Constructing Array 1 |
ユーザー |
![]() |
提出日時 | 2020-03-09 20:59:04 |
言語 | C (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 1 ms / 1,000 ms |
コード長 | 123 bytes |
コンパイル時間 | 1,347 ms |
コンパイル使用メモリ | 26,368 KB |
実行使用メモリ | 6,820 KB |
最終ジャッジ日時 | 2024-11-14 06:53:26 |
合計ジャッジ時間 | 1,656 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 6 |
コンパイルメッセージ
main.c: In function 'main': main.c:3:5: warning: implicit declaration of function 'scanf' [-Wimplicit-function-declaration] 3 | scanf("%d",&a); | ^~~~~ main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'scanf' +++ |+#include <stdio.h> 1 | int main(void){ main.c:3:5: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch] 3 | scanf("%d",&a); | ^~~~~ main.c:3:5: note: include '<stdio.h>' or provide a declaration of 'scanf' main.c:4:14: warning: implicit declaration of function 'printf' [-Wimplicit-function-declaration] 4 | if(a>10){printf("10 %d\n",a-10);} | ^~~~~~ main.c:4:14: note: include '<stdio.h>' or provide a declaration of 'printf' main.c:4:14: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch] main.c:4:14: note: include '<stdio.h>' or provide a declaration of 'printf' main.c:5:10: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch] 5 | else{printf("1 %d\n",a-1); | ^~~~~~ main.c:5:10: note: include '<stdio.h>' or provide a declaration of 'printf'
ソースコード
int main(void){int a;scanf("%d",&a);if(a>10){printf("10 %d\n",a-10);}else{printf("1 %d\n",a-1);}}