結果

問題 No.2480 Sequence Sum
ユーザー とりゐとりゐ
提出日時 2023-09-22 21:24:03
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 78 ms / 500 ms
コード長 218 bytes
コンパイル時間 283 ms
コンパイル使用メモリ 87,144 KB
実行使用メモリ 75,736 KB
最終ジャッジ日時 2023-10-04 12:32:50
合計ジャッジ時間 2,259 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 69 ms
71,488 KB
testcase_01 AC 71 ms
71,544 KB
testcase_02 AC 78 ms
75,484 KB
testcase_03 AC 75 ms
75,480 KB
testcase_04 AC 74 ms
75,428 KB
testcase_05 AC 72 ms
75,612 KB
testcase_06 AC 74 ms
75,300 KB
testcase_07 AC 72 ms
75,576 KB
testcase_08 AC 75 ms
75,512 KB
testcase_09 AC 74 ms
75,484 KB
testcase_10 AC 74 ms
75,480 KB
testcase_11 AC 75 ms
75,500 KB
testcase_12 AC 73 ms
75,628 KB
testcase_13 AC 73 ms
75,420 KB
testcase_14 AC 75 ms
75,736 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

def divisors(n):
  lower,upper=[],[]
  i=1
  while i*i<=n:
    if n%i==0:
      lower.append(i)
      if i!=n//i:
        upper.append(n//i)
    i+=1
  return lower+upper[::-1]

n=int(input())
print(n-len(divisors(n)))
0