結果
| 問題 | No.543 命題 |
| コンテスト | |
| ユーザー |
suppy193
|
| 提出日時 | 2020-03-20 14:34:55 |
| 言語 | C90 (gcc 12.4.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 128 bytes |
| 記録 | |
| コンパイル時間 | 217 ms |
| コンパイル使用メモリ | 19,840 KB |
| 実行使用メモリ | 6,820 KB |
| 最終ジャッジ日時 | 2024-12-14 04:10:53 |
| 合計ジャッジ時間 | 579 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | WA * 4 |
コンパイルメッセージ
main.c: In function ‘main’:
main.c:6:13: warning: format ‘%s’ expects argument of type ‘char *’, but argument 2 has type ‘char (*)[3]’ [-Wformat=]
6 | scanf("%s", &p);
| ~^ ~~
| | |
| | char (*)[3]
| char *
main.c:6:5: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
6 | scanf("%s", &p);
| ^~~~~~~~~~~~~~~
ソースコード
#include <stdio.h>
int main(void)
{
char p[3];
scanf("%s", &p);
printf("%c %c\n", p[2], p[0]);
return 0;
}
suppy193