Submission #28922932


Source Code Expand

N = input()
LIM = str(2147483647)
is_minus = False

if '-' in N:
    is_minus = True
    N = N[1:]
    LIM = str(2147483648)

if len(LIM) < len(N):
    print("No")
    exit()

elif len(N) < len(LIM):
    print("Yes")
    exit()

else:
    for i in range(len(N)):
        if int(LIM[i]) < int(N[i]):
            print("No")
            exit()

print("Yes")

Submission Info

Submission Time
Task A - Not Overflow
User is0292hx
Language Python (3.8.2)
Score 100
Code Size 380 Byte
Status AC
Exec Time 22 ms
Memory 9056 KiB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 100 / 100
Status
AC × 3
AC × 10
Set Name Test Cases
Sample example_00.txt, example_01.txt, example_02.txt
All example_00.txt, example_01.txt, example_02.txt, hand_00.txt, hand_01.txt, hand_02.txt, hand_03.txt, hand_04.txt, hand_05.txt, hand_06.txt
Case Name Status Exec Time Memory
example_00.txt AC 20 ms 8824 KiB
example_01.txt AC 21 ms 9008 KiB
example_02.txt AC 20 ms 8940 KiB
hand_00.txt AC 20 ms 8824 KiB
hand_01.txt AC 22 ms 8940 KiB
hand_02.txt AC 21 ms 8880 KiB
hand_03.txt AC 20 ms 8888 KiB
hand_04.txt AC 20 ms 9056 KiB
hand_05.txt AC 19 ms 8888 KiB
hand_06.txt AC 19 ms 8876 KiB