아직 만들고 있는 페이지입니다.

이 페이지는 아직 만드는 중입니다. 보이는 내용은 바뀔 수 있습니다.

Divide

시간 제한1.8초메모리 제한1024 MB

요약
1 이상 p 이하인 a와 1 이상 q 이하인 b 중에서 a*b가 a+b로 나누어떨어지고 그 몫이 n 이하인 쌍의 수를 구한다.
난이도

보통10점 중 7점

유형
수학, 정수론, 완전 탐색
정답자
아직 제출이 없습니다

문제

Who doesn’t love math 🙂

Let pp, qq and nn be natural numbers. We will say that a pair of natural numbers (a,b)(a, b) is interesting when:

  1. 1≤a≤p1 ≤ a ≤ p
  2. 1≤b≤q1 ≤ b ≤ q
  3. c=a×ba+bc = \frac{a \times b}{a + b} is a natural number, and 1≤c≤n1 ≤ c ≤ n, that is the product a×ba \times b is divisible without remainder by the sum a+ba + b, and their quotient is less than or equal to nn.

The goal of this task is simple - find the number of interesting pairs!

Write a program divide, that given the three numbers pp, qq and nn, computes the number of interesting pairs.

입력

The only line of the standard input contains the numbers pp, qq and nn.

출력

On the single line of the standard output, print the number of interesting pairs. It is guaranteed that the answer less than 101810^{18}.

제한

  • 1≤p,q,n≤10101 ≤ p, q, n ≤ 10^{10}

예제1

  1. 예제 1

    입력
    13 17 5
    
    예상 출력
    11