結果

問題 No.278 連続する整数の和(2)
ユーザー niyarinniyarin
提出日時 2016-11-08 18:14:04
言語 Python2
(2.7.18)
結果
RE  
実行時間 -
コード長 215 bytes
コンパイル時間 85 ms
コンパイル使用メモリ 7,072 KB
実行使用メモリ 815,364 KB
最終ジャッジ日時 2024-05-03 23:25:48
合計ジャッジ時間 1,745 ms
ジャッジサーバーID
(参考情報)
judge2 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 11 ms
6,816 KB
testcase_01 AC 11 ms
6,944 KB
testcase_02 RE -
testcase_03 WA -
testcase_04 WA -
testcase_05 MLE -
testcase_06 -- -
testcase_07 -- -
testcase_08 -- -
testcase_09 -- -
testcase_10 -- -
testcase_11 -- -
testcase_12 -- -
testcase_13 -- -
testcase_14 -- -
testcase_15 -- -
testcase_16 -- -
testcase_17 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

N = input()
if N == 1:
    print 1
elif N == 2:
    print 1
else:
    v = N if N%2 else N/2
    ans = 0
    for i in range(1,v/2+1):
        if v % i == 0:
            ans += i
            ans += v/i
    print ans

0