結果
問題 |
No.632 穴埋め門松列
|
ユーザー |
![]() |
提出日時 | 2025-04-01 14:02:11 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 1 ms / 1,000 ms |
コード長 | 196 bytes |
コンパイル時間 | 453 ms |
コンパイル使用メモリ | 26,752 KB |
実行使用メモリ | 7,324 KB |
最終ジャッジ日時 | 2025-04-01 14:02:12 |
合計ジャッジ時間 | 882 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 6 |
コンパイルメッセージ
main.cpp: In function ‘int main()’: main.cpp:5:14: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 5 | scanf("%c %c %c", &str[0], &str[1], &str[2]); | ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ソースコード
#include<stdio.h> int main() { char str[3]; scanf("%c %c %c", &str[0], &str[1], &str[2]); if (str[1] == '?') printf("14\n"); else if (str[1] == '2') printf("4\n"); else printf("1\n"); }