You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A builder is looking to build a row of N houses that can be of K different colors. He has a goal of minimizing cost while ensuring that no two neighboring houses are of the same color.
Given an N by K matrix where the nth row and kth column represents the cost to build the nth house with kth color, return the minimum cost which achieves this goal.
The text was updated successfully, but these errors were encountered:
A builder is looking to build a row of
N
houses that can be ofK
different colors. He has a goal of minimizing cost while ensuring that no two neighboring houses are of the same color.Given an
N
byK
matrix where the nth row and kth column represents the cost to build the nth house with kth color, return the minimum cost which achieves this goal.The text was updated successfully, but these errors were encountered: