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

6815번 - Cool Numbers 다국어

시간 제한메모리 제한제출정답맞힌 사람정답 비율
1 초 128 MB30017213363.942%

문제

Eric likes interesting numbers like 64. It turns out that 64 is both a square and a cube, since 64 = 82 and 64 = 43. Eric calls these numbers cool.

Write a program that helps Eric figure out how many integers in a given range are cool.

입력

On the first line of input, you are given an integer a such that a ≥ 1 and a ≤ 108. On the second line of input, you are given an integer b such that a ≤ b and b ≤ 108.

출력

The output should be the number of cool numbers in the range a to b (inclusively: that is, a and b would count as cool numbers in the range if they were actually cool).

제한

예제 입력 1

1
100

예제 출력 1

2

예제 입력 2

100
1000

예제 출력 2

1

힌트

출처

Olympiad > Canadian Computing Competition & Olympiad > 2009 > CCC 2009 Senior Division 1번

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

출처

대학교 대회

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

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