Maximum houses a Robber can rob

There are several houses in a society where the security system of two adjacent house is connected. Hence, if a robber robs two adjacent house, police is informed automatically and the robber does not want this to happen. The robber has the information of how much money is stored in each house. The robber needs to rob alternative houses to be safe.


The robber wants to know how many houses can be robbed without informing the police.


Given a list of non-negative integers representing the amount o...

 •  0 comments  •  flag
Share on Twitter
Published on June 01, 2020 05:17
No comments have been added yet.