Writen by Chris Piech
Karel is starting to find her world too black and white. Help her fill it with color.
Karel has a few commands up her sleeve. She can paint the corner on which she is standing using the instruction
Karel also defines a new condition random, which is true half the time, but in an unpredictable way. Like flipping a coin, sometimes it is true and sometimes it is false. For example the code
Use these new abilities to have karel randomly paint each corner of a world one of two colors. You can chose any two colors you would like; we chose green and blue.
Below are three executions of the same program that randomly paints any sized world green and blue executed on a 10x10 world. Note that because of the random condition, the pattern of green and blue is different on each run!
As always, remember to decompose your solution! Your program should work on a world of any size.