i want a program which counts the number of colour used in an image becauise im only allowed to use 8 colours for my project.

thanks, and advice also welcome tnx