結果
| 問題 | No.111 あばばばば |
| コンテスト | |
| ユーザー |
カルロス
|
| 提出日時 | 2015-09-03 10:10:15 |
| 言語 | C90(gcc12) (gcc 12.4.0) |
| 結果 |
AC
|
| 実行時間 | 195 ms / 5,000 ms |
| + 717µs | |
| コード長 | 183 bytes |
| 記録 | |
| コンパイル時間 | 42 ms |
| コンパイル使用メモリ | 29,440 KB |
| 実行使用メモリ | 5,888 KB |
| 最終ジャッジ日時 | 2026-07-24 02:44:37 |
| 合計ジャッジ時間 | 1,915 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 10 |
コンパイルメッセージ
main.c: In function ‘main’:
main.c:6:5: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
6 | scanf("%d", &L);
| ^~~~~~~~~~~~~~~
ソースコード
#include <stdio.h>
int main(void){
int i, L;
long long ans = 0;
scanf("%d", &L);
for(i=L-2;i>0;i-=2){
ans+=i;
}
printf("%lld\n", ans);
return 0;
}
カルロス