DMOPC '15 Contest 5 P1 - Gel Bananas
View as PDFOkabe and Kurisu are experimenting on bananas. Okabe starts a new experiment every  days, and Kurisu starts a new experiment every 
 days. Today, on day 
, Okabe and Kurisu both start an experiment. How many times will Okabe and Kurisu start their experiments together in 
 days?
Input Specification
The first, second and third lines of input will contain , 
 
, and 
 
, respectively.
Output Specification
Output a single integer, the number of times that Okabe and Kurisu start their experiments together.
Sample Input
2
3
10
Sample Output
2
Explanation
Okabe will start his experiments on days , 
, 
, 
, 
 and Kurisu will start her experiments on days 
, 
, 
, 
. They start their experiments together on days 
 and 
.
Comments
El psy congaro?
Qx Bek Oazsdaa
https://dmoj.ca/problem/encode