結果
問題 | No.278 連続する整数の和(2) |
ユーザー | 👑 testestest |
提出日時 | 2015-11-06 15:47:53 |
言語 | C90 (gcc 11.4.0) |
結果 |
TLE
|
実行時間 | - |
コード長 | 101 bytes |
コンパイル時間 | 454 ms |
コンパイル使用メモリ | 19,840 KB |
実行使用メモリ | 13,752 KB |
最終ジャッジ日時 | 2024-09-13 13:04:14 |
合計ジャッジ時間 | 3,756 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 0 ms
13,752 KB |
testcase_01 | AC | 0 ms
6,940 KB |
testcase_02 | TLE | - |
testcase_03 | -- | - |
testcase_04 | -- | - |
testcase_05 | -- | - |
testcase_06 | -- | - |
testcase_07 | -- | - |
testcase_08 | -- | - |
testcase_09 | -- | - |
testcase_10 | -- | - |
testcase_11 | -- | - |
testcase_12 | -- | - |
testcase_13 | -- | - |
testcase_14 | -- | - |
testcase_15 | -- | - |
testcase_16 | -- | - |
testcase_17 | -- | - |
コンパイルメッセージ
main.c:1:10: warning: data definition has no type or storage class 1 | long s,n;i;main(){for(scanf("%ld",&n),n/=2-n%2;n>++i*i;s+=n%i?0:i+n/i);i=!printf("%ld",n-i*i?s:s+i);} | ^ main.c:1:10: warning: type defaults to ‘int’ in declaration of ‘i’ [-Wimplicit-int] main.c:1:12: warning: return type defaults to ‘int’ [-Wimplicit-int] 1 | long s,n;i;main(){for(scanf("%ld",&n),n/=2-n%2;n>++i*i;s+=n%i?0:i+n/i);i=!printf("%ld",n-i*i?s:s+i);} | ^~~~ main.c: In function ‘main’: main.c:1:23: warning: implicit declaration of function ‘scanf’ [-Wimplicit-function-declaration] 1 | long s,n;i;main(){for(scanf("%ld",&n),n/=2-n%2;n>++i*i;s+=n%i?0:i+n/i);i=!printf("%ld",n-i*i?s:s+i);} | ^~~~~ main.c:1:1: note: include ‘<stdio.h>’ or provide a declaration of ‘scanf’ +++ |+#include <stdio.h> 1 | long s,n;i;main(){for(scanf("%ld",&n),n/=2-n%2;n>++i*i;s+=n%i?0:i+n/i);i=!printf("%ld",n-i*i?s:s+i);} main.c:1:23: warning: incompatible implicit declaration of built-in function ‘scanf’ [-Wbuiltin-declaration-mismatch] 1 | long s,n;i;main(){for(scanf("%ld",&n),n/=2-n%2;n>++i*i;s+=n%i?0:i+n/i);i=!printf("%ld",n-i*i?s:s+i);} | ^~~~~ main.c:1:23: note: include ‘<stdio.h>’ or provide a declaration of ‘scanf’ main.c:1:75: warning: implicit declaration of function ‘printf’ [-Wimplicit-function-declaration] 1 | long s,n;i;main(){for(scanf("%ld",&n),n/=2-n%2;n>++i*i;s+=n%i?0:i+n/i);i=!printf("%ld",n-i*i?s:s+i);} | ^~~~~~ main.c:1:75: note: include ‘<stdio.h>’ or provide a declaration of ‘printf’ main.c:1:75: warning: incompatible implicit declaration of built-in function ‘printf’ [-Wbuiltin-declaration-mismatch] main.c:1:75: note: include ‘<stdio.h>’ or provide a declaration of ‘printf’
ソースコード
long s,n;i;main(){for(scanf("%ld",&n),n/=2-n%2;n>++i*i;s+=n%i?0:i+n/i);i=!printf("%ld",n-i*i?s:s+i);}