Nodes fixed by a group reversal
A list of nodes, numbered through in their starting order, is reversed in consecutive groups of (reverse nodes –, then –, and so on; divides evenly into groups). After the reversal, how many nodes remain in the same position they started in?
Show hints (2)+
- Reversing an odd-length block leaves its middle element in place.
- Count the blocks (), then one fixed node per odd block.
Answer
Reveal answer →Final answer
5
Create a free account to see the full worked solution and track your progress.
Interview format: Hedge Fund Quant, Trading Aptitude Tests