Circular houses => cannot take both first and last.
Compute max of two linear robberies:
[0..n-2][1..n-1]
Use House Robber I DP for each.Any optimal set either includes the first (thus excludes last) or excludes first (thus may include last).
Circular houses => cannot take both first and last.
Compute max of two linear robberies:
[0..n-2][1..n-1]
Use House Robber I DP for each.Any optimal set either includes the first (thus excludes last) or excludes first (thus may include last).