Available question text
Starting from n, repeatedly add any i in [1,n] for which some current board value x satisfies x % i == 1, and after many iterations return the number of distinct integers present. Equivalently, compute the size of the reachability/closure set in a directed graph with edges x → i whenever x % i == 1 (n ≤ 100).
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 2549. Count Distinct Numbers on Board
Reported date not specified · 0 source reports
Source snapshot: Nov 12, 2026
View source