题解 | 求最小公倍数
a, b = map(int, input().split()) M = max(a, b) N = min(a, b) for i in range(1, N+1): if (M * i) % N == 0: break print(M * i)
a, b = map(int, input().split()) M = max(a, b) N = min(a, b) for i in range(1, N+1): if (M * i) % N == 0: break print(M * i)
相关推荐