Test case file format:
- One line, containing one integer N, which is the number of images contained in the test case file
- N times, the following format:
- One line, containing the name of the image to be tested
- One line, containing one integer M, which is the number of colors to be found for this image
- M lines, each containing three space separated integers, which represent an RGB color.
Here's a sample showing how the algorithm works (Pixels are colored red as they are examined):