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

11379번 - Avoider 다국어

시간 제한메모리 제한제출정답맞힌 사람정답 비율
1 초 256 MB69322856.000%

문제

Consider points with integer coordinates in the plane. We start from the origin, make a first step towards the point (1, 0) and then every next step is a move to one of the four neighboring integer points (up, down, left or right) so that we are always at a point with nonnegative coordinates. Moreover, it is not allowed to visit twice a point. Let us count how many different routes of the described kind we may obtain using n steps. For example, when n = 2, 3 and 4, counting the routes gives 2, 5 and 12, respectively.

Write program avoider that inputs two positive integers a and b (0 < a < b < 29) and displays the sum of counting the number of routes for values of n = a, a + 1, ..., b.

입력

Two positive integers a and b (0 < a < b < 29)

출력

The sum of counting the number of routes for values of n = a, a + 1, ..., b.

제한

예제 입력 1

2 4

예제 출력 1

19

힌트

출처

Olympiad > International Autumn Tournament in Informatics > 2014 > Group B (Juniors) 1번

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

출처

대학교 대회

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

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