PROJECT EULER · #0732
Standing on the Shoulders of Trolls
- the distance from his feet to his shoulders in cm,
- the length of his arms in cm,
- his IQ (Irascibility Quotient),
.
Trolls can pile up on top of each other, with each troll standing on the shoulders of the one below him. A troll can climb out of the hole and escape if his hands can reach to the surface. Once a troll escapes he cannot participate any further in the escaping effort.
The trolls execute an optimal strategy for maximizing the total IQ of the escaping trolls, defined as
Let
For example, the first troll (
You are given that
Find
Write-up coming later
The complete problem is available here. An approach, code, and answer will be added later.