Point constraints
You are trying to create an array $A$ containing $N$ integers. However, your array-creating-machine has some restrictions. More formally, you are given a constant $D$, and two arrays $B$ and $C$, each with $M$ elements, then: - $A_i \le D$ for all $1 \le i \le N$ - $A_i \ge A_{i - 1}$ for all $1 \lt i \le N$ - $A_{C_j}\cdot B_j \le D$ for all $1 \le j \le M$ Find how many different arrays can you
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start