結果
| 問題 | No.299 蟻本が読めない |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2017-12-17 17:53:00 |
| 言語 | C90(gcc12) (gcc 12.4.0) |
| 結果 |
AC
|
| 実行時間 | 1 ms / 1,000 ms |
| コード長 | 89 bytes |
| 記録 | |
| コンパイル時間 | 112 ms |
| コンパイル使用メモリ | 28,104 KB |
| 実行使用メモリ | 7,840 KB |
| 最終ジャッジ日時 | 2026-03-08 16:15:20 |
| 合計ジャッジ時間 | 511 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 4 |
コンパイルメッセージ
main.c: In function ‘main’:
main.c:3:5: warning: incompatible implicit declaration of built-in function ‘scanf’ [-Wbuiltin-declaration-mismatch]
3 | scanf("%ld", &n);
| ^~~~~
main.c:1:1: note: include ‘<stdio.h>’ or provide a declaration of ‘scanf’
+++ |+#include <stdio.h>
1 | main(){
main.c:3:14: warning: format ‘%ld’ expects argument of type ‘long int *’, but argument 2 has type ‘long long int *’ [-Wformat=]
3 | scanf("%ld", &n);
| ~~^ ~~
| | |
| | long long int *
| long int *
| %lld
main.c:4:5: warning: incompatible implicit declaration of built-in function ‘printf’ [-Wbuiltin-declaration-mismatch]
4 | printf("%ld\n",316 + (n-1)*52);
| ^~~~~~
main.c:4:5: note: include ‘<stdio.h>’ or provide a declaration of ‘printf’
main.c:4:15: warning: format ‘%ld’ expects argument of type ‘long int’, but argument 2 has type ‘long long int’ [-Wformat=]
4 | printf("%ld\n",316 + (n-1)*52);
| ~~^ ~~~~~~~~~~~~~~
| | |
| long int long long int
| %lld
ソースコード
main(){
long long int n;
scanf("%ld", &n);
printf("%ld\n",316 + (n-1)*52);
}