Submission #615989


Source Code Expand

import sys
import math

def nicos(N):
    nico_canidate = []
    seed = "25"
    nowstr = seed
    while(int(nowstr) <= N):
        nico_canidate.append(int(nowstr))
        nowstr += seed
    return nico_canidate

N = int(sys.stdin.readline().rstrip())
seeds = nicos(N)
ans = set()
for seed in seeds:
    for k in range(1, int(math.ceil(float(N)/seed))):
        ans.add(seed*k)

print len(ans)
exit(0)

Submission Info

Submission Time
Task A - ニコニコ数
User hiking
Language Python (2.7.3)
Score 0
Code Size 425 Byte
Status WA
Exec Time 2648 ms
Memory 1048576 KB

Judge Result

Set Name Sample Subtask1
Score / Max Score 0 / 0 0 / 60
Status
AC × 2
AC × 9
WA × 3
TLE × 2
MLE × 3
Set Name Test Cases
Sample sample_01.txt, sample_02.txt
Subtask1 sample_01.txt, sample_02.txt, test_01.txt, test_02.txt, test_03.txt, test_04.txt, test_05.txt, test_06.txt, test_07.txt, test_08.txt, test_09.txt, test_10.txt, test_11.txt, test_12.txt, test_13.txt, test_14.txt, test_15.txt
Case Name Status Exec Time Memory
sample_01.txt AC 63 ms 3380 KB
sample_02.txt AC 662 ms 95000 KB
test_01.txt AC 67 ms 3240 KB
test_02.txt WA 57 ms 3384 KB
test_03.txt AC 62 ms 3296 KB
test_04.txt WA 65 ms 4520 KB
test_05.txt AC 81 ms 7452 KB
test_06.txt AC 792 ms 101388 KB
test_07.txt WA 205 ms 26520 KB
test_08.txt MLE 2155 ms 1048576 KB
test_09.txt MLE 2143 ms 1048576 KB
test_10.txt TLE 2648 ms 835868 KB
test_11.txt MLE 2334 ms 1048576 KB
test_12.txt TLE 2634 ms 588560 KB
test_13.txt AC 818 ms 101404 KB
test_14.txt AC 59 ms 3392 KB
test_15.txt AC 57 ms 3372 KB