Submission #1341132


Source Code Expand

#!/usr/bin/env python3

import collections

def color(r):
    for i, (p, q) in enumerate([
            (1, 399),
            (400, 799),
            (800, 1199),
            (1200, 1599),
            (1600, 1999),
            (2000, 2399),
            (2400, 2799),
            (2800, 3199),
            (3200, 4800)
    ]):
        if p <= r <= q:
            return i

input()
a = collections.Counter([color(int(x)) for x in input().split()])
m = len(a) - (1 if 8 in a and len(a) > 1 else 0)
print(m, m + a[8])

Submission Info

Submission Time
Task C - Colorful Leaderboard
User p_km
Language Python (3.4.3)
Score 0
Code Size 513 Byte
Status WA
Exec Time 57 ms
Memory 3564 KB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 0 / 300
Status
AC × 3
AC × 7
WA × 1
Set Name Test Cases
Sample s1.txt, s2.txt, s3.txt
All in1.txt, in2.txt, in3.txt, in4.txt, in5.txt, s1.txt, s2.txt, s3.txt
Case Name Status Exec Time Memory
in1.txt WA 57 ms 3564 KB
in2.txt AC 20 ms 3316 KB
in3.txt AC 20 ms 3316 KB
in4.txt AC 20 ms 3316 KB
in5.txt AC 20 ms 3316 KB
s1.txt AC 20 ms 3316 KB
s2.txt AC 20 ms 3316 KB
s3.txt AC 20 ms 3316 KB