House Robber V
Rob houses in a row with a rule that two neighbours of the same colour cannot both be taken; a two-state dynamic programme tracks whether the previous house was robbed.
Rob houses in a row with a rule that two neighbours of the same colour cannot both be taken; a two-state dynamic programme tracks whether the previous house was robbed.