Time limit: 1s
Memory limit: 256MB
Input:
Output:
Statement
is testing your programming skills with a problem he solved in his youth, when his informatics skills were much lower than they are now.The problem sounds as follows:
Find the sum of integers between and (inclusive) that are not multiples of or .
Input data
The input comprises a single line featuring three integers, denoted as , , and , satisfying the inequalities , , . These integers bear significance in accordance with the context provided in the problem statement.
Output data
Print the answer.
Example 1
stdin
10 3 5
stdout
22
Note
The integers between and (inclusive) that are not multiples of or are and whose sum is .
Example 2
stdin
1000000000 314 159
stdout
495273003954006262