結果
問題 |
No.3108 Luke or Bishop
|
ユーザー |
|
提出日時 | 2025-04-19 09:39:27 |
言語 | C (gcc 13.3.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 141 bytes |
コンパイル時間 | 782 ms |
コンパイル使用メモリ | 24,576 KB |
実行使用メモリ | 7,848 KB |
最終ジャッジ日時 | 2025-04-19 09:39:29 |
合計ジャッジ時間 | 1,805 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 15 WA * 11 |
コンパイルメッセージ
main.c: In function ‘main’: main.c:6:12: warning: implicit declaration of function ‘abs’ [-Wimplicit-function-declaration] 6 | if(abs(gx) == abs(gy)){ | ^~~ main.c:2:1: note: include ‘<stdlib.h>’ or provide a declaration of ‘abs’ 1 | #include<stdio.h> +++ |+#include <stdlib.h> 2 | main.c:5:9: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 5 | scanf("%d %d",&gx,&gy); | ^~~~~~~~~~~~~~~~~~~~~~
ソースコード
#include<stdio.h> int main(void){ int gx,gy; scanf("%d %d",&gx,&gy); if(abs(gx) == abs(gy)){ printf("1"); } else{ printf("2"); } }