Eating Skittles Like a Normal Person Skittles are colored candy where there are 5 distinct flavors; grape, green apple, lemon, orange, and strawberry represented by (p)urple, (g)reen, (y)ellow, (o)range, and (r)ed respectively. I used to eat skittles by sorting all the different colors, then eating them in sequence. After getting a few weird looks in the office, I now pretend to eat them like a normal person. Your task is to emulate this:

Your code (full program or function) will receive an array of skittles (10x10) as input (in any reasonable format). This array will represent a pile of unsorted skittles. Your task is to "eat" them from your least favorite to favorite color. My preferred order is grape, green apple, lemon, orange, strawberry, but you are free to choose any order so long as it is consistently enforced (please list your preference in your submission so I can judge you for it). After eating each piece of candy your code will output (in the same format you take input) the remaining pile with the eaten piece replaced by a space. You will repeat until only your favorite remains. You may choose any skittle to eat (may be random or deterministic). Trailing spaces must be kept.

For example, your output sequence could look like this (using 5x5 for brevity and showing spaces as .)

start   1     2     3     4     5        n 
.org. .org. .org. .org. .or.. .or..    ..r..
prgrg .rgrg .rgrg .rgrg .rgrg .r.rg    .r.r.
gggpr gggpr ggg.r ggg.r ggg.r ggg.r    ....r
oyyor oyyor oyyor oyyor oyyor oyyor    ....r
.r.p. .r.p. .r.p. .r... .r... .r...    .r...


This is code-golf, so shortest code in bytes wins

TL;DR Rules:


Submission may be full program or function
Input may be taken in any reasonable format (string, list, matrix, etc) by any reasonable method (STDIN, function arguments, etc.). However there must be some delineation between rows
Output must be produced in the same format as input by any reasonable method (STDOUT, function return, ect.). Intermediate output may or may not be delimited
First output shall be the first input
Trailing spaces must be preserved
Any color order may be used (list in your answer)
Any skittle of the current color may be eaten
Last output shall be only your favorite color and spaces
If possible, include a link to an online compiler to test your submission
Jelly, 16 14&nbsp; 13 bytes

Ṅ⁶ỤṪ$¦µQL&gt;3µ¿


TryItOnline!

Most to least favourite, as for anyone serious about their O.C.D., is alphabetical!

Takes input and outputs as text (i.e. the rows are delimited by new lines).

3 bytes saved by reversing the direction and using a different method: grade up rather than finding characters from the alphabet.

How?

Ṅ⁶ỤṪ$¦µQL&gt;3µ¿ - Main link: Skittle text
      µ    µ  - monadic chain separation
            ¿ - while
       Q      - unique items
        L     - length
         &gt;3   - greater than 3 (until only new lines, spaces and 'g's remain)
Ṅ             -     print z and a line feed, yield z
    $         -     treat last two links as a monad
  Ụ           -         grade up (get indices of: new lines; spaces; gs; os; ps; rs; ys)
   Ṫ          -         tail (the last of those, so last y if there is one, else last r, ...)
 ⁶            -     space character
     ¦        -     apply at index (replace that index with a space)