← All problemsSign in

Four Arrays

CodeChefRating 2709Open on judge ↗

You have been given an integer $K$ and four arrays $A$, $B$, $C$, and $D$ with sizes $S_A$, $S_B$, $S_C$ and $S_D$ respectively. Follow the given steps: - Pick four indices $x$, $y$, $z$, and $w$ from arrays $A$, $B$, $C$, and $D$ respectively. Note that $(1 \le x \le S_A)$, $(1 \le y \le S_B)$, $(1 \le z \le S_C)$ and $(1 \le w \le S_D)$. - There are in total $S_A\times S_B\times S_C\times S_D

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.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start