color prediction game algorithm