Short Rainbow explainer

The aim of this puzzle: Draw 7 boxes using letters, rather than words, to define their colors.
Walkthrough of the solution: drawBoxes() will draw a box for every letter typed inside it. So drawBoxes('y') would draw one box and drawBoxes('yy') would draw two boxes (in this case both boxes would be yellow). For this puzzle you need to draw 7 boxes so will need 7 letters. If you want to continue the rainbow pattern you should add 'i' (indigo) and 'v' (violet). A collection of letters between quote marks is called a string, or str.
Sample code solution:
(Tap below to reveal)


JavaScript Concepts: Calling Functions
Grasshopper Concepts: drawBoxes()