A simple optimization problem
Note: The program makes 10 clusters by default. Please update _ClusterNo for more or less number of clusters. On changing _ClusterNo please update 'color' vector with appropriate number of color values.
The code has been improved and can process 10's of MBs of data within minutes.