結果
| 問題 |
No.8004 愛国心
|
| コンテスト | |
| ユーザー |
moti
|
| 提出日時 | 2015-12-23 23:41:59 |
| 言語 | C90 (gcc 12.3.0) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 89 bytes |
| コンパイル時間 | 150 ms |
| コンパイル使用メモリ | 19,456 KB |
| 実行使用メモリ | 5,376 KB |
| 最終ジャッジ日時 | 2024-09-18 21:46:33 |
| 合計ジャッジ時間 | 1,546 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | RE * 5 |
コンパイルメッセージ
main.c:1:1: warning: return type defaults to ‘int’ [-Wimplicit-int]
1 | main() {
| ^~~~
main.c: In function ‘main’:
main.c:3:9: warning: implicit declaration of function ‘getc’ [-Wimplicit-function-declaration]
3 | while(c=getc()) {
| ^~~~
main.c:5:1: warning: implicit declaration of function ‘printf’ [-Wimplicit-function-declaration]
5 | printf("%d\n", s[c-1-'0']);
| ^~~~~~
main.c:1:1: note: include ‘<stdio.h>’ or provide a declaration of ‘printf’
+++ |+#include <stdio.h>
1 | main() {
main.c:5:1: warning: incompatible implicit declaration of built-in function ‘printf’ [-Wbuiltin-declaration-mismatch]
5 | printf("%d\n", s[c-1-'0']);
| ^~~~~~
main.c:5:1: note: include ‘<stdio.h>’ or provide a declaration of ‘printf’
ソースコード
main() {
int c;
while(c=getc()) {
char s[10]="yukicoder";
printf("%d\n", s[c-1-'0']);
}
}
moti