Available question text
Starting from an array of n ones, apply k rounds of replacing each element by the prefix sum up to that index and return a[n-1] modulo 1e9+7. Key insight: the value equals the binomial coefficient C(n+k-1, k), so the problem reduces to computing that combination mod 1e9+7 (n,k ≤ 1000).
Related questions
Continue with questions that share topics or the same question type.
Sources · 1 reference
These records explain where the question appears. A company tag or candidate report does not guarantee a future interview question.
Hello Interview · 1 record
No company association
Leetcode 3179. Find the N-th Value After K Seconds
Reported date not specified · 0 source reports
Source snapshot: Nov 12, 2026
View source