N,K,L = map(int,input().split()) P = 10 ** 9 + 7 def seki(x,y): l = [[0] * N for _ in range(N)] for i in range(N): for j in range(N): for k in range(N): l[i][j] = (l[i][j] + x[i][k] * y[k][j]) % P return l A = [[0] * N for _ in range(N)] for i in range(N): for x in range(1,L+1): A[(i+x)%N][i] += 1 tmp = [[0] * N for _ in range(N)] for i in range(N): tmp[i][i] = 1 while K: if K & 1: tmp = seki(tmp,A) A = seki(A,A) K >>= 1 for i in range(N): print(tmp[i][0])