Purpose: Children create rectangles (arrays) of varying sizes by painting rows of square tiles (in colors they can choose) and moving up or down to paint more rows. The puzzles may ask for certain dimensions (number or length of rows) or the total number of squares in the rectangle (area). Sometimes puzzles ask for rectangles to be subdivided into halves (or thirds) of different colors. Children learn by experimenting and seeing the effect of their work, so preteaching is not needed. They must sometimes predict results or puzzle out how to get results that aren’t obvious (e.g., partitioning the larger grid into several different colored rectangles).
Work is not “checked” as in tutorial apps and games. Children see the effects their code produces and change it if they like. Children can mark “I did it!” on a checklist sheet (as a pdf) as they do the puzzles.
Description: The stage shows a grid with 7 rows of 10 squares. At the start of any puzzle (and whenever the button is pressed), the arrow () which acts as a paintbrush starts in the first square of row 1 (top left).
Four programming blocks , , and move the arrow (). Children can specify a particular row to start at, using . Children can choose a color with the and then use the block to specify the number of squares to paint.
As always, children can choose new explorations, puzzles, and challenges (Figure 3).
Figure 3: Three puzzles from the Array microworld
Introducing this in class: Children who have worked in the Number Line and Map microworlds can generally figure out what the new blocks in this microworld do with a brief introduction—less than 10 minutes—and some experimentation. Show how to drag out a blue block and how to click; let children describe what happens. Have a child come up to demonstrate another move.
Next invite a child to demonstrate how to select pen color and paint a row of ( _ ) squares. Ask children how to paint more than one row. Demonstrate move down one row and paint a row of ( _ ) squares again to make a rectangle with two rows (or more than two rows, if you like). Have a child show how to use the start at row block by typing in a number and then clicking the block. Point out how to get a new puzzle. Let children do much of the demonstrating. They can then work independently.
Children may need to be shown (or reminded) how to insert scripts into the repeat block.
Teacher notes: