[LeetCode] Nth Magical Number

1 · · Feb. 23, 2022, 1:19 p.m.
878. Nth Magical Number A positive integer is magical if it is divisible by either a or b. Given the three integers n, a, and b, return the nth magical number. Since the answer may be very large, return it modulo 109 + 7. ...