You have to lose all your cards to win. You have to type the first letter of the color that you want to keep.
Thx to TNTsquirrel. Credit even goes to the players.