Кравченко Роман, 420 SwapFive 644 | Богданов Евгений 524 SwapFive 1648 | ||||
---|---|---|---|---|---|
t | 1 | a = int(input()) | t | 1 | k = int(input()) |
2 | b = 10 * a - 1 | 2 | x = 10 * k - 1 | ||
3 | lst = [] | 3 | a = [] | ||
4 | while a not in lst: | 4 | while k not in a: | ||
5 | lst += [a] | 5 | a += [k] | ||
6 | print(10 * a // b, sep='', end='') | 6 | print(10 * k // x, sep='', end='') | ||
7 | a = 10 * a % b | 7 | k = 10 * k % x |
Legends | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
|
|