Your canvas
Every CodeLab sketch draws onto a 400 × 400 square canvas. Positions are measured in pixels from the top-left corner, which is (0, 0). The x value grows to the right, and — this trips everyone up at first — the y value grows downward.
Coordinates
The center of the canvas is (200, 200). The bottom-right corner is (400, 400).
Drawing shapes
rect(x, y, w, h) draws a rectangle whose top-left corner is at (x, y). ellipse(x, y, w, h) draws an ellipse centered at (x, y). Try editing the example below and press Run: