You are a professional robber planning to rob houses along a street. Each house has a certain amount of money stashed, the only constraint stopping you from robbing each of them is that adjacent houses have security system connected and it will automatically contact the police if two adjacent houses were broken into on the same night.
执行用时 :4 ms, 在所有 C++ 提交中击败了80.13%的用户 内存消耗 :8.4 MB, 在所有 C++ 提交中击败了93.46%的用户