Gold Mining
Chef and Chefu are working as gold miners. There are a total of $N$ gold mines, numbered $1$ through $N$. For each valid $i$, the $i$-th gold mine contains $G_i$ gold in total; if only Chef worked in it, it would take him $A_i$ days to completely mine it, while if only Chefu worked in it, it would take him $B_i$ days. Each of our miners may only work in one mine at a time, but they may decide t
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