結果
問題 |
No.547 未知の言語
|
ユーザー |
![]() |
提出日時 | 2025-03-14 13:32:27 |
言語 | C (gcc 13.3.0) |
結果 |
RE
|
実行時間 | - |
コード長 | 280 bytes |
コンパイル時間 | 371 ms |
コンパイル使用メモリ | 24,448 KB |
実行使用メモリ | 7,328 KB |
最終ジャッジ日時 | 2025-03-14 13:32:33 |
合計ジャッジ時間 | 5,707 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | RE * 33 |
コンパイルメッセージ
main.c: In function ‘main’: main.c:6:9: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 6 | scanf("%d",&val); | ^~~~~~~~~~~~~~~~ main.c:11:17: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 11 | scanf("%s%s",str1,str2); | ^~~~~~~~~~~~~~~~~~~~~~~
ソースコード
#include <stdio.h> #include <string.h> int main(){ int val = 0; scanf("%d",&val); char *str1 = "test"; char *str2 = "test"; for(int i = 0;i < val;i ++){ scanf("%s%s",str1,str2); if(str1 != str2){ printf("%d\n%s\n%s\n",i + 1,str1,str2); return 0; } } }