Young treasure hunter Roma took a course in the specialty "pantry thing" and now runs a summer practice. Summer practice is near the village of "Dawn Stone" and lasts exactly
b days. Every day the novel is
a coin buried in the vicinity. Thus, at the end of the first day, he had
a coin at the end of the second — 2·a, and at the end of practice at the Roma must be accumulated b·a coin.
If at the end of the day the responsible teacher noticed that the number is divisible by Romas coins
b, the Roma were allowed to take off the shelf cake, which he immediately ate. Romas help calculate how many pies he eats during an internship.
The first line contains two integers
1 ≤ a,
b ≤ 109).
The output file output the number of pies eaten Roma.