Logo
(追記) (追記ここまで)

15106번 - Fear Factoring 다국어

시간 제한메모리 제한제출정답맞힌 사람정답 비율
1 초 512 MB34320816162.646%

문제

The Slivians are afraid of factoring; it’s just, well, difficult.

Really, they don’t even care about the factors themselves, just how much they sum to.

We can define F(n) as the sum of all of the factors of n; so F(6) = 12 and F(12) = 28. Your task is, given two integers a and b with a ≤ b, to calculate

\[S=\sum_{a \le n \le b}{F(n)}\]

입력

The input consists of a single line containing space-separated integers a and b (1 ≤ a ≤ b ≤ 1012; b − a ≤ 106).

출력

Print S on a single line.

제한

예제 입력 1

101 101

예제 출력 1

102

예제 입력 2

28 28

예제 출력 2

56

예제 입력 3

1 10

예제 출력 3

87

예제 입력 4

987654456799 987654456799

예제 출력 4

987654456800

예제 입력 5

963761198400 963761198400

예제 출력 5

5531765944320

예제 입력 6

5260013877 5260489265

예제 출력 6

4113430571304040

힌트

출처

ICPC > Regionals > North America > Pacific Northwest Regional > 2017 Pacific Northwest Region Programming Contest > Division 1 C번

ICPC > Regionals > North America > Pacific Northwest Regional > 2017 Pacific Northwest Region Programming Contest > Division 2 P번

(追記) (追記ここまで)

출처

대학교 대회

  • 사업자 등록 번호: 541-88-00682
  • 대표자명: 최백준
  • 주소: 서울시 서초구 서초대로74길 29 서초파라곤 412호
  • 전화번호: 02-521-0487 (이메일로 연락 주세요)
  • 이메일: contacts@startlink.io
  • 통신판매신고번호: 제 2017-서울서초-2193 호

AltStyle によって変換されたページ (->オリジナル) /