How many rearrangements \((p_1, p_2, \ldots, p_{1000})\) of the sequence \(1, 2, \ldots, 1000\) satisfy that for any integer \(1 \leq i \leq 999\), we have \(i \mid p_i\)?

Let's think step by step and output the final answer within \boxed{}.
user