Harryxun/stf_run huggingface dataset:
N,D,A = map(int,input().split())
import numpy as np
import math
XH = [list(map(int,input().split())) for _ in range(N)]
XH = sorted(XH)
ans = 0
ma = XH[-1][0]
l = np.array([0]*(ma+5))
for xh in XH:
  l[xh[0]]=xh[1]
  

for xh in XH:
  x = xh[0]
  if x+2*D<=ma:
    a = l[x]
    if a<=0:
      continue
    else:
      b = math.ceil(a/A)
      ans += b
      l[x:x+2*D+1:]-=b*A
  else:
    a = l[x]
    if a<=0:
      continue
    else:
      b=math.ceil(a/A)
      ans += b
      l[x::]-=b*A
      
print(ans)

### FIXED CODE ###

def main():
  N,D,A = map(int,input().split())
  XH = [list(map(int,input().split())) for _ in range(N)]
  XH = sorted(XH)
  ans = 0
  S = [0]*(N+1)
  x = XH[0][0]
  h = XH[0][1]
  j = 0
  b = (h+A-1)//A
  ans += b
  y = b*A
  while True:
    if j+1>=N:
      break
    if XH[j+1][0]<=x+2*D:
      j+=1
    else:
      break
  S[0]+=y
  S[j+1]-=y
  S[1]+=S[0]
  for i in range(1,N):
    xh = XH[i]
    h = xh[1]
    s = S[i]
    rec = h-s
    if rec<=0:
      S[i+1]+=s
      continue
    else:
      x = xh[0]
      j = max(j,i)
      while True:
        if j+1>=N:
          break
        if XH[j+1][0]<=x+2*D:
          j+=1
        else:
          break
      b = (rec+A-1)//A
      ans += b
      y = b*A
      S[i]+=y
      S[j+1]-=y
      S[i+1]+=s+y
  print(ans)
main()
s = input()
t = input()
while s != "":
  x = s[0]
  y = t[0]
  for i in range(len(s)):
    if (s[i] == "x" and t[i] != "y") or (s[i] != "x" and t[i] == "y"):
      print("No")
      exit()
  s = s.replace(x,"")
  t = t.replace(y,"")
print("Yes")

### FIXED CODE ###

s = input()
t = input()
while s != "":
  x = s[0]
  y = t[0]
  for i in range(len(s)):
    if (s[i] == x and t[i] != y) or (s[i] != x and t[i] == y):
      print("No")
      exit()
  s = s.replace(x,"")
  t = t.replace(y,"")
print("Yes")
N, A = map(int, input().split())
X = list(map(int, input().split()))
for i in range(N):
    X[i] -= A

dp = defaultdict(int)
dp[0] = 1

for x in X:
    
    for j, c in list(dp.items()):
        dp[j + x] += c

print(dp[0]-1)


### FIXED CODE ###

from collections import defaultdict

N, A = map(int, input().split())
X = list(map(int, input().split()))
for i in range(N):
    X[i] -= A

dp = defaultdict(int)
dp[0] = 1

for x in X:
    
    for j, c in list(dp.items()):
        dp[j + x] += c

print(dp[0]-1)
h,n = map(int,input().split())

ls = [list(map(int,input().split())) for _ in range(n)]

amax = max(a for a,b in ls)

dp = [0]*(h+amax)

for i in range(1,h+amax):
  dp[i] = min(dp[max(0,i-a)]+b for a,b in ls)

print(min(dp[h:]))



### FIXED CODE ###

import math

a,b = map(int,input().split())

print(math.ceil(a/b))
yandy
H, W = map(int, input().split())
S = [input() for _ in range(H)]

A = [''] * H

di = [(1,0),(-1,0),(0,1),(0,-1),(1,1),(1,-1),(-1,1),(-1,-1)]

for h in range(H):
    for w in range(W):
        if S[h][w] == '#':
            A[h] += '#'
        else:
            c = 0
            for d in di:
                h1 = h + d[0]
                w1 = w + d[1]
                if 0 <= h1 < H and 0 <= w1 < W:
                    if S[h1][w1] == '#':
                        c += 1
            A[h] += str(c)

for i in range(H):
    print(A[i])



### FIXED CODE ###

H, W = map(int, input().split())
S = [input() for _ in range(H)]

A = [''] * H

di = [(1,0),(-1,0),(0,1),(0,-1),(1,1),(1,-1),(-1,1),(-1,-1)]

for h in range(H):
    for w in range(W):
        if S[h][w] == '#':
            A[h] += '#'
        else:
            c = 0
            for d in di:
                h1 = h + d[0]
                w1 = w + d[1]
                if 0 <= h1 < H and 0 <= w1 < W:
                    if S[h1][w1] == '#':
                        c += 1
            A[h] += str(c)

for i in range(H):
    print(A[i])
for i in range(1,9):
    for j in range(1,9):
        print "%d x %d = %d" % (i,j,i*j))

### FIXED CODE ###

for i in range(1,10):
    for j in range(1,10):
        print "%dx%d=%d" % (i,j,(i*j))
n, m = [int(x) for x in input().split()]
l = [0] * m
r = [0] * m
for i in range(m):
    l[i], m[i] = map(int, input().split())

L = max(l)
R = min(r)

if L <= R:
    print(R - L + 1)
else:
    print(0)

### FIXED CODE ###

n, m = [int(x) for x in input().split()]
l = [0] * m
r = [0] * m
for i in range(m):
    l[i], r[i] = map(int, input().split())

L = max(l)
R = min(r)

if L <= R:
    print(R - L + 1)
else:
    print(0)
n=int(input())
x=input()
x_popcount=x.count('1')
f=[0]*(x_popcount+1)
for i in range(1,x_popcount+1):
    popcount=format(i,'b').count('1')
    f[i]=f[i%popcount]+1
# print(f)
for i in range(len(x)):
    if x[i]=='1':
        x_changed=x[:i]+'0'+x[i+1:]
        popcount=x_popcount-1
    else:
        x_changed=x[:i]+'1'+x[i+1:]
        popcount=x_popcount+1
    num_changed=int(x_changed,2)
    # print(x_changed,num_changed)
    if num_changed<popcount:
        print(f[num_changed])
    else:
        print(f[num_changed%popcount]+1)

### FIXED CODE ###

## 最初のmodをどうにか高速にやりたい → modの性質を使う
## xiのpopcount（1の数）はxのpopcount+1または-1
n=int(input())
x_str=input()
x_popcount=x_str.count('1')
dp=[0]*(x_popcount+1)
for i in range(1,x_popcount+1):
    popcount=format(i,'b').count('1')
    dp[i]=dp[i%popcount]+1
# print(dp)
# x=int(x_str,2)
if x_popcount>1:
    pows_minus=[pow(2,i,(x_popcount-1)) for i in range(n)]
    # x_minus=x%(x_popcount-1)
    x_minus=0
    for i in range(n):
        if x_str[i]=='1':
            x_minus+=pows_minus[n-1-i]
pows_plus=[pow(2,i,(x_popcount+1)) for i in range(n)]
# x_plus=x%(x_popcount+1)
x_plus=0
for i in range(n):
    if x_str[i]=='1':
        x_plus+=pows_plus[n-1-i]

for i in range(len(x_str)):
    ## xi=xi mod popcount(x)+-1
    xi=-1
    if x_str[i]=='1':
        if x_popcount>1: ## else: xi=-1
            xi=(x_minus-pows_minus[n-1-i])%(x_popcount-1)
    else:
        xi=(x_plus+pows_plus[n-1-i])%(x_popcount+1)
    if xi==-1:
        print(0)
    else:
        print(dp[xi]+1)
n, m = map(int, input().split())
sc = [list(map(int, input().split())) for i in range(m)]
sorted(sc)

def f1():
    if m == 0:
        return 0
    l = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
    for i in l:
        for j in range(m):
            if i == s[m][1]:
                return i
    return -1

def f2():
    if m == 0:
        return 10
    for i in range(1, m):
        if sc[i - 1][0] == sc[i][0] and sc[i - 1][1] != sc[i][1]:
            return -1
    l = [10 * i + j for i in range(1, 10) for j in range(0, 10)]
    sl = ["1", "0"]
    for i in range(m):
        sl[sc[i][0] - 1] = str(sc[i][1])
    s = sl[0] + sl[1]
    for i in l:
        if str(i) == s:
            return i
    return -1

def f3():
    if m == 0:
        return 100
    for i in range(1, m):
        if sc[i - 1][0] == sc[i][0] and sc[i - 1][1] != sc[i][1]:
            return -1
    l = [100 * i + 10 * j + k for i in range(1, 10) for j in range(0, 10) for k in range(0, 10)]
    sl = ["1", "0", "0"]
    for i in range(m):
        sl[sc[i][0] - 1] = str(sc[i][1])
    s = sl[0] + sl[1] + sl[2]
    for i in l:
        if str(i) == s:
            return i
    return -1

if n == 1:
    print(f1())
elif n == 2:
    print(f2())
else:
    print(f3())


### FIXED CODE ###

n, m = map(int, input().split())
sc = [list(map(int, input().split())) for i in range(m)]
sorted(sc)

def f1():
    if m == 0:
        return 0
    for i in range(1, m):
        if sc[i - 1][0] == sc[i][0] and sc[i - 1][1] != sc[i][1]:
            return -1
    """
    l = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
    for i in l:
        for j in range(m):
            if i == s[j][1]:
                return i
    return -1
    """
    return sc[0][1]

def f2():
    if m == 0:
        return 10
    for i in range(1, m):
        if sc[i - 1][0] == sc[i][0] and sc[i - 1][1] != sc[i][1]:
            return -1
    l = [10 * i + j for i in range(1, 10) for j in range(0, 10)]
    sl = ["1", "0"]
    for i in range(m):
        sl[sc[i][0] - 1] = str(sc[i][1])
    s = sl[0] + sl[1]
    for i in l:
        if str(i) == s:
            return i
    return -1

def f3():
    if m == 0:
        return 100
    for i in range(1, m):
        if sc[i - 1][0] == sc[i][0] and sc[i - 1][1] != sc[i][1]:
            return -1
    l = [100 * i + 10 * j + k for i in range(1, 10) for j in range(0, 10) for k in range(0, 10)]
    sl = ["1", "0", "0"]
    for i in range(m):
        sl[sc[i][0] - 1] = str(sc[i][1])
    s = sl[0] + sl[1] + sl[2]
    for i in l:
        if str(i) == s:
            return i
    return -1

if n == 1:
    print(f1())
elif n == 2:
    print(f2())
else:
    print(f3())
while 1:
    m=input().split()
    h=int(m[0])
    w=int(m[1])
    if a==0 & b==0:
      break
    for i in range(h):
       print("#"*w)
    print()
    
    


### FIXED CODE ###

while True:
    v=input().split()
    a=int(v[0])
    b=int(v[1])
    if a==0 and b==0:
       break
    for i in range (a):
        print('#'*b)
    print()
n,k=map(int,input().split())
l=list(map(int,input().split()))
now=1
s=set()
jnbn=[]
for x in range(n):
  now=l[now-1]
  s.add(now)
  jnbn.append(now)
l=len(s)
#繰り返しの暫定長さを求めた
if 1 in s:
  an=k%l
  print(jnbn[an-1])
else:
  nl=l-1
  an=k%nl
  print(jnbn[an-1])

### FIXED CODE ###

n, k = map(int, input().split())
li = list(map(int, input().split()))
 
check = [0] * (n+10)
res = []
next = 0
 
for i in range(k):
    if check[next] == 0:
        check[next] = 1
        next = li[next]-1
    elif check[next] == 1:
        check[next] += 1
        res.append(next+1)
        next = li[next]-1
    else:
        cnt = len(res)
        k -= check.count(1)
        amari = k%cnt
        print(res[amari])
        break
else:
    print(next+1)
[h, w] =raw_input().split()
for height in range(h):
    if height == h-1 or height == 0:
        print "#"*w
    else:
        print "#"+ "."*(w-2)+"#"

### FIXED CODE ###

while True:
    h,w = tuple([int(x) for x in raw_input().split(" ")])
    if h==0 and w==0: break
 
    for ih in range(h):
        if ih==0 or ih==h-1 or w <= 2: print "#" * w
        else: print "#" + "." * (w-2) + "#"
 
    print ""
n = input()

for i in range(1, 10):
    if n <= i*111:
        print(i*111)
        exit()


### FIXED CODE ###

import re
import sys

n = int(input())

for i in range(n, 1000):
    if re.match('^([0-9])\\1+$', str(i)):
        print(i)
        sys.exit(0)
if a==b==c:print('1')
elif a==b or b==c or c==a:print('2')
else:print('3')

### FIXED CODE ###

a,b,c = list(map(int,input().split()))
if a==b==c:print('1')
elif (a==b and c!=a) or (b==c and a!=b) or (c==a and b!=c):print('2')
else:print('3')
import math
N = int(input())

xs = list(range(N))

print(sum(xs))

### FIXED CODE ###


import math
N = int(input())
print(int(N * (N - 1) // 2))
l = list(input())
a = [int(x) for x in l]
prtint(sum(a))

### FIXED CODE ###

l = list(input())
a = [int(x) for x in l]
print(sum(a))
from collections import deque

def bfs():
  queue = deque([[0, 0]])
  visited[0][0] = 0
  while queue:
    y, x = queue.popleft()
    if [y, x] == [h-1, w-1]:
      return visited[y][x]
    for j, k in ([1, 0], [-1, 0], [0, 1], [0, -1]):
      new_y, new_x = y+j, x+k
      if (0 <= new_y < h) and (0 <= new_x < w):
        if maze[new_y][new_x] == "." and visited[new_y][new_x] == -1:
          visited[new_y][new_x] = visited[y][x] + 1
          queue.append([new_y, new_x])
          
h,w = map(int, input().split())

maze=[]
w_space=0
for _ in range(h):
  t=input()
  maze.append(t)
  w_space += t.count(".")

visited = [[-1]*w for _ in range(h)]

ans = bfs()
if ans != -1:
  print(w_space - ans - 1)
else:
  print(-1)

### FIXED CODE ###

from collections import deque

def bfs():
  queue = deque([[0, 0]])
  visited[0][0] = 0
  while queue:
    y, x = queue.popleft()
    if [y, x] == [h-1, w-1]:
      return visited[y][x]

    for j, k in ([1, 0], [-1, 0], [0, 1], [0, -1]):
      new_y, new_x = y+j, x+k
      if not (0 <= new_y < h) or not (0 <= new_x < w):
        continue

      if maze[new_y][new_x] == "." and visited[new_y][new_x] == -1:
        visited[new_y][new_x] = visited[y][x] + 1
        queue.append([new_y, new_x])

h,w = map(int, input().split())

maze=[]
w_space=0
for _ in range(h):
  t=input()
  maze.append(t)
  w_space += t.count(".")
visited = [[-1]*w for _ in range(h)]

ans = bfs()
if ans and ans != -1:
  print(w_space - ans - 1)
else:
  print(-1)
def a:return "Yes" if "".join(sorted(list(input())))=="abc" else "No"
print(a())

### FIXED CODE ###

S=list(input())
S.sort()
if S[0]=="a" and S[1]=="b" and S[2]=="c":
  print("Yes")
else:
  print("No")
x=input();print(["NO","YES"][x in ["3","5","7"])

### FIXED CODE ###

x=int(input())
if x==5 or x==7 or x==3:
    print("YES")
else:
    print("NO")
import sys

N, K = map(int, sys.stdin.readline().split())
A = list(map(int, sys.stdin.readline().split())) * K

count = 0

for i in range(0, K * N - 1):
    for j in range(1, K * N):
        if i < j and A[i] > A[j]:
            count = count + 1

ans = count % (10 ** 9 + 7)
print(ans)

### FIXED CODE ###

import sys


def main():
    N, K = map(int, sys.stdin.readline().split())
    A = list(map(int, sys.stdin.readline().split()))

    count1 = 0
    count2 = 0

    for i in range(N - 1):
        for j in range(i + 1, N):
            if A[i] > A[j]:
                count1 = count1 + 1
            if A[i] != A[j]:
                count2 = count2 + 1
    count1 = count1 * K
    count2 = count2 * (K * (K - 1) // 2)

    ans = (count1 + count2) % 1000000007
    print(ans)


if __name__ == "__main__":
    main()
while 1:
    n=int(input())
    cnt=0
    for i in range(10):
        for j in range(10):
            for k in range(10):
                for l in range(10):
                    if i+j+k+l==n:
                        cnt=cnt+1
    print(cnt)

### FIXED CODE ###

import sys
for line in sys.stdin:
    n=int(line)
    cnt=0
    for i in range(10):
        for j in range(10):
            for k in range(10):
                for l in range(10):
                    if i+j+k+l==n:
                        cnt=cnt+1
    print(cnt)
def main():
	# a,b,k = map(int,input().split())
	n,k = map(int,input().split())
	# s = int(input())
	# a = list(map(int,input().split()))
	# rsp = list(str(input()))
	# l = [list(map(int, input().split())) for _ in range(n-1)]
	# s = list(s)

	if n < 10 or k < 10:
		print(int(n*k))	
 	else:
 		print(-1)

 
if __name__ == '__main__':
	main()

### FIXED CODE ###

def main():
	# a,b,k = map(int,input().split())
	n,k = map(int,input().split())
	# s = int(input())
	# a = list(map(int,input().split()))
	# rsp = list(str(input()))
	# l = [list(map(int, input().split())) for _ in range(n-1)]
	# s = list(s)
 
	if n < 10 and k < 10:
		print(int(n*k))
	else:
 		print(-1)
 
 
if __name__ == '__main__':
	main()
import math

N = int(input())

A = list(map(int,input().split()))

A = sorted(A)[0:2]

print(math.gcd(A[0],A[1]))


### FIXED CODE ###

import fractions
from functools import reduce

def gcd(numbers):
    return reduce(fractions.gcd, numbers)

N = int(input())

A = list(map(int,input().split()))

print(gcd(A))
a,b,c = map(int,input().split())
if b - a = c - b:
    print("YES")
else:
    print("NO")

### FIXED CODE ###

a,b,c = map(int,input().split())
if b - a == c - b:
    print("YES")
else:
    print("NO")
while 1:
  a,op,b = map(raw_input().split())
  if op == "+":
    print a + b
  elif op == "-":
    print a - b
  elif op == "*":
    print a * b
  elif op == "/":
    print a / b
  else:
    break
  

### FIXED CODE ###

while 1:
  s = raw_input().split()
  a, b =int(s[0]), int(s[2])
  op = s[1] 

  if op == "+":
    print "%d" %(a + b)
  elif op == "-":
    print "%d" %(a - b)
  elif op == "*":
    print "%d" %(a * b)
  elif op == "/":
    print "%d" %(a / b)
  else:
    break
#coding: utf-8
import sys
N = int(input())
l = []
for i in range(N):
    a = list(map(int, input().split()))
    if a[2] > 0:
      l.append(a)
    if N == 1:
      print(a[0], a[1], a[2])
      sys.exit()

for i in range(len(l)-1):
    ans = []
    for cx in range(101):
        for cy in range(101):
          if l[i][2] + abs(l[i][0] - cx) + abs(l[i][1] - cy) == l[i+1][2] + abs(l[i+1][0] - cx) + abs(l[i+1][1] - cy):
            if i == 0:
              ans.append([cx, cy])
            else:
              if [cx, cy] in ansn:
                ans.append([cx, cy])
    ansn = ans[:]
    if len(ans) == 1:
        break

print(ans[0][0], ans[0][1], l[0][2] + abs(l[0][0] - ans[0][0]) + abs(l[0][1] - ans[0][1]))

### FIXED CODE ###

#coding: utf-8
N = int(input())
l = []
for i in range(N):
    a = list(map(int, input().split()))
    if a[2] > 0:
      l.append(a)
if len(l) >= 2:
    for i in range(len(l)-1):
        ans = []
        for cx in range(101):
            for cy in range(101):
                if l[i][2] + abs(l[i][0] - cx) + abs(l[i][1] - cy) == l[i+1][2] + abs(l[i+1][0] - cx) + abs(l[i+1][1] - cy) and l[i][2] != 0 and l[i+1][2] != 0:
                    if i == 0:
                        ans.append([cx, cy])
                    else:
                        if [cx, cy] in ansn:
                            ans.append([cx, cy])
        ansn = ans[:]
        if len(ans) == 1:
            break
    print(ans[0][0], ans[0][1], l[0][2] + abs(l[0][0] - ans[0][0]) + abs(l[0][1] - ans[0][1]))
else:
    print(l[0][0], l[0][1], l[0][2])
N = input()

if N[0] == N[1] and N[1]== N[2]:
    print ('Yes')
elif N[1] == N[2] and N[2]== N[3]:
    print ('Yes')
elif N[2] == N[3] and N[3]== N[4]:
    print ('Yes')
elif N[0] == N[1] and N[1]== N[2] and N[2]== N[3]:
    print ('Yes')
else:
    print ('No')

### FIXED CODE ###

N = input()
if (N[0] == N[1] == N[2]) or (N[1] == N[2] == N[3]):
    print("Yes")
else:
    print("No")
N = int(input())
x = [None]*N
y = [None]*N
h = [None]*N

for i in range(N):
    x[i],y[i],h[i] = map(int, input().split())

def height(X,Y,xn,yn,hn):
    return hn+abs(X-xn)+abs(Y-yn)

def check(x,y,h,X,Y,H):
    for n in range(N):
        if h[n]>0:
            if height(X,Y,x[n],y[n],h[n])!=H:
                return False
        else:
            if H-abs(X-x[n])-abs(Y-y[n])>0:
            return False
    return True

for X in range(101):
    for Y in range(101):
        for n in range(N):
            H = height(X,Y,x[n],y[n],h[n])
            if check(x,y,h,X,Y,H) is True:
                print(X,Y,H)
                exit()


### FIXED CODE ###

N = int(input())
x = [None]*N
y = [None]*N
h = [None]*N

for i in range(N):
    x[i],y[i],h[i] = map(int, input().split())

def height(X,Y,xn,yn,hn):
    return hn+abs(X-xn)+abs(Y-yn)

def check(x,y,h,X,Y,H):
    for n in range(N):
        if h[n]>0:
            if height(X,Y,x[n],y[n],h[n])!=H:
                return False
        elif H-abs(X-x[n])-abs(Y-y[n])>0:
            return False
    return True

for X in range(101):
    for Y in range(101):
        for n in range(N):
            if h[n]>0:
                H = height(X,Y,x[n],y[n],h[n])
                if check(x,y,h,X,Y,H) is True:
                    print(X,Y,H)
                    exit()
import sys

A, B, M = map(int, sys.stdin.readline().rstrip().split())
a = list(map(int, sys.stdin.readline().rstrip().split()))
b = list(map(int, sys.stdin.readline().rstrip().split()))
xyc = [list(map(int, sys.stdin.readline().rstrip().split())) for i in range(M)]
ans = 10 ** 9 + 7
mans = min(a) + min(b)
for xyci in xyc:
    tmp = a[xyci[0] - 1] + a[xyci[1] - 1] - xyci[2]
    if ans > tmp:
        ans = tmp

print(min(tmp, mans))


### FIXED CODE ###

import sys

A, B, M = map(int, sys.stdin.readline().rstrip().split())
a = list(map(int, sys.stdin.readline().rstrip().split()))
b = list(map(int, sys.stdin.readline().rstrip().split()))
xyc = [list(map(int, sys.stdin.readline().rstrip().split())) for i in range(M)]
ans = min(a) + min(b)

for xyci in xyc:
    x, y, c = xyci
    tmp = a[x - 1] + b[y - 1] - c
    if ans > tmp:
        ans = tmp

print(ans)
A, B = int(input()), int(input())

# AとBの偶奇が一致する場合 存在する
# AとBの偶奇が一致しない場合 存在しない

if (A % 2 != B % 2):
    print("IMPOSSIBLE")
else:
    k = int((A + B) / 2)
    print(k)

### FIXED CODE ###

input_arr = input().split(" ")
A = int(input_arr[0])
B = int(input_arr[1])

# AとBの偶奇が一致する場合 存在する
# AとBの偶奇が一致しない場合 存在しない

if (A % 2 != B % 2):
    print("IMPOSSIBLE")
else:
    k = int((A + B) / 2)
    print(k)
r = input()
s =2*math.pi*r
v =math.pi*r^2

print(s,v)


### FIXED CODE ###

import math
r = float(input())
v = math.pi*r*r
s = math.pi*r*2

print('%.7f %.7f'%(v,s))
N = int(input())
print(sum(list(range(N))))


### FIXED CODE ###

N = int(input())
print((N-1) * N // 2)
a = input().split(" ")
num = [0 for i in range(int(a[0]))] 
for i in range(int(a[1])):
    a = input().split(" ")
    num[int(a[0])-1] = num[int(a[0])-1]+1
    num[int(a[1])-1] = num[int(a[1])-1]+1

for i in range(int(a[1])):
    print(num[i])

### FIXED CODE ###

def siritori(a):
    s1 = int(a[0])
    s2 = int(a[1])
    s3 = int(a[2])
    if s1<=s3 and s3<=s2:
        print("Yes")
    else:
        print("No")

siritori(input().split(" "))
S = int(input())
mod = 10 ** 9 + 7

if S <= 2:
    print(0)
    exit()

ans = 0
max_items = S // 3

# print("max_items", max_items)

for item in range(1, max_items + 1):
    # print("---------------------------")
    n = S - 3 * item
    modinv_table = [-1] * (n + 1)
    modinv_table[1] = 1
    for i in range(2, n + 1):
        modinv_table[i] = (-modinv_table[mod % i] * (mod // i)) % mod

    add = 1
    for p in range(n):
        add *= (n + item - 1) - p
        add *= modinv_table[p + 1]
        add %= mod

    # print("item", item)
    # print("n", n)
    # print("add", add)


    ans += add
    ans %= mod



print(ans)


### FIXED CODE ###

S = int(input())
mod = 10 ** 9 + 7

if S <= 2:
    print(0)
    exit()

ans = 0
max_items = S // 3

# print("max_items", max_items)

for item in range(1, max_items + 1):
    # print("---------------------------")
    # print("item", item)
    n = S - 3 * item
    # print("n", n)
    if n == 0:
        ans += 1
        break

    modinv_table = [-1] * (n + 1)
    modinv_table[1] = 1
    for i in range(2, n + 1):
        modinv_table[i] = (-modinv_table[mod % i] * (mod // i)) % mod

    add = 1
    for p in range(n):
        add *= (n + item - 1) - p
        add *= modinv_table[p + 1]
        add %= mod


    # print("add", add)


    ans += add
    ans %= mod



print(ans)
n=int(input())
a=0
x=int(n**0.5)
for m in range(1,int(x)+1):
    a+=m*(m+n//m)*(n//m+1-m)
print(int(a-x*(1+x)/(1-x)**4+1))

### FIXED CODE ###

import math
def s(): return input()
def i(): return int(input())
def S(): return input().split()
def I(): return map(int,input().split())
def L(): return list(input().split())
def l(): return list(map(int,input().split()))
def numdiv(n):
    table = [0] * (n + 1)
    
    for i in range(1, n + 1):
        for j in range(i, n + 1, i):
            table[j] += 1
    
    return table
N = i()
era = numdiv(N)
ans = 0
for i in range(1,N+1):
    ans += era[i]*i
print(ans)
a, b = map(int,input().split())
d = a/b
r = a%b
f = (double)a/b
print(d, r, f)
 

### FIXED CODE ###

a, b = map(int,input().split())
d = a // b 
r = a % b
f = a / b
print("%d %d %f" %(d,r,f))
L = input()
ans = (L//3)**3
print(ans)

### FIXED CODE ###

N, M = map(int, input().split())
ans = N*(N-1)//2 + M*(M-1)//2
print(ans)