Maximum Color Frequency in DAG Paths - Coding problem | OneNoughtOne