import strscans func calc(x, y: int): (int, int) = let v1 = 100 * x / (x + y) v2 = 100 * y / (x + y) (v1.toInt, v2.toInt) var (_, a, b) = stdin.readLine.scanTuple "$i $i" x = 1 y = 0 if a < b: swap(a, b) while true: let (c, d) = calc(x, y) if (c, d) == (a, b): break if c < a: inc x else: inc y echo x + y