Submission #34432636


Source Code Expand

import sys
import collections
import itertools

sys.setrecursionlimit(250000)
deb = 0
INF = float('inf')
MINF = -INF

a, b = map(int,input().split())
_a = a 
_b = b
while True : 
    if a < b : a, b = b, a 
    if a % b == 0 : g = b; break 
    else :a -= (a//b) * b 

ans =  (_a//g) * (_b//g) * g 
if ans > 10**18 : print('Large')
else : print(ans)

Submission Info

Submission Time
Task 038 - Large LCM(★3)
User ay24h
Language PyPy3 (7.3.0)
Score 3
Code Size 370 Byte
Status AC
Exec Time 70 ms
Memory 64928 KiB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 3 / 3
Status
AC × 3
AC × 45
Set Name Test Cases
Sample sample_01.txt, sample_02.txt, sample_03.txt
All hand_01.txt, hand_02.txt, hand_03.txt, hand_04.txt, hand_05.txt, hand_06.txt, hand_07.txt, hand_08.txt, hand_09.txt, hand_10.txt, hand_11.txt, hand_12.txt, hand_13.txt, hand_14.txt, hand_15.txt, hand_16.txt, hand_17.txt, random_01.txt, random_02.txt, random_03.txt, random_04.txt, random_05.txt, random_06.txt, random_07.txt, random_08.txt, random_09.txt, random_10.txt, random_11.txt, random_12.txt, random_13.txt, random_14.txt, random_15.txt, random_16.txt, random_17.txt, random_18.txt, random_19.txt, random_20.txt, random_21.txt, random_22.txt, random_23.txt, random_24.txt, random_25.txt, sample_01.txt, sample_02.txt, sample_03.txt
Case Name Status Exec Time Memory
hand_01.txt AC 70 ms 64840 KiB
hand_02.txt AC 53 ms 64636 KiB
hand_03.txt AC 53 ms 64872 KiB
hand_04.txt AC 53 ms 64848 KiB
hand_05.txt AC 57 ms 64888 KiB
hand_06.txt AC 52 ms 64688 KiB
hand_07.txt AC 54 ms 64560 KiB
hand_08.txt AC 50 ms 64836 KiB
hand_09.txt AC 55 ms 64632 KiB
hand_10.txt AC 55 ms 64844 KiB
hand_11.txt AC 54 ms 64460 KiB
hand_12.txt AC 54 ms 64644 KiB
hand_13.txt AC 55 ms 64692 KiB
hand_14.txt AC 54 ms 64656 KiB
hand_15.txt AC 53 ms 64928 KiB
hand_16.txt AC 55 ms 64644 KiB
hand_17.txt AC 54 ms 64580 KiB
random_01.txt AC 53 ms 64848 KiB
random_02.txt AC 54 ms 64476 KiB
random_03.txt AC 56 ms 64876 KiB
random_04.txt AC 56 ms 64540 KiB
random_05.txt AC 54 ms 64560 KiB
random_06.txt AC 54 ms 64668 KiB
random_07.txt AC 54 ms 64672 KiB
random_08.txt AC 53 ms 64556 KiB
random_09.txt AC 56 ms 64892 KiB
random_10.txt AC 56 ms 64648 KiB
random_11.txt AC 53 ms 64852 KiB
random_12.txt AC 54 ms 64688 KiB
random_13.txt AC 51 ms 64672 KiB
random_14.txt AC 57 ms 64904 KiB
random_15.txt AC 56 ms 64884 KiB
random_16.txt AC 53 ms 64840 KiB
random_17.txt AC 55 ms 64568 KiB
random_18.txt AC 54 ms 64668 KiB
random_19.txt AC 56 ms 64916 KiB
random_20.txt AC 56 ms 64692 KiB
random_21.txt AC 52 ms 64912 KiB
random_22.txt AC 54 ms 64536 KiB
random_23.txt AC 51 ms 64540 KiB
random_24.txt AC 58 ms 64876 KiB
random_25.txt AC 55 ms 64852 KiB
sample_01.txt AC 51 ms 64632 KiB
sample_02.txt AC 56 ms 64872 KiB
sample_03.txt AC 52 ms 64564 KiB