https://practice.geeksforgeeks.org/problems/m-coloring-problem/0