http://www.nxcoding.com/archives/leetcode-daily-1931-color-grid-dynamic-programming