지나가던 개발자

[Python] 백준 14490번(백대열) 문제 풀이 본문

PS/Python

[Python] 백준 14490번(백대열) 문제 풀이

KwonYongHyeon 2022. 11. 10. 18:04

 

import math

n, m = map(int, input().split(":"))
print(str(n//math.gcd(n, m))+":"+str(m//math.gcd(n, m)))
Comments