Playgrounds

A playground is an environment for messing around — games to hack on, drawing and animation frameworks, REPLs, and other scratch spaces — open to everyone, independent of any class or assignment. Nothing you do in a playground is saved beyond this browser, so experiment freely. (If you are looking for demonstrations of the site's coding-assignment machinery, those are the demos.)

Games

2048 Build the sliding-tile game: a grid, arrow keys, and merge logic. Chess board Draw a chess board with Unicode pieces; add legal-move display if you're ambitious. Connect Four Implement Connect Four: the board, legal moves, and win detection. Hangman Make a hangman game. Maze solver A drawing environment for building and solving mazes. Platformer The animation framework plus key-press handling — build a little platformer. Sudoku The chess-board drawing environment, pointed at Sudoku.

Drawing & animation

Bouncing ball The classic first programming exercise: make a ball bounce. Simple draw A freeform drawing canvas with simple shape functions. Simple animation Simple draw plus an animate loop: draw one frame at a time. Flag Draw a properly proportioned US flag from rectangles and stars. Game of life Implement Conway's Game of Life in the animation framework.

Javascript

Javascript REPL A code editor plus a REPL for experimenting with Javascript. Number function practice Practice translating arithmetic and geometric expressions into functions. Advent of Code An editor and REPL set up for working Advent of Code puzzles.

Java

Java execution Write a Java class on the left, see your program's output on the right. JShell jshell, Java's REPL: type expressions, no class or main required. MadLibs Write a MadLib — practice with methods that do something other than math. Simple graphics Draw with the full java.awt.Graphics API. Squares Simple graphics plus a Square class — practice constructing and manipulating objects. Finals graphics The open-ended java.awt.Graphics environment from the fall final.

Snap!

Snap! Snap!, the blocks-based language, embedded in the site as a scratch space.

Machines

Shell A real bash terminal on your own disposable Linux machine. teacher login or demo code Swing Run real Java Swing programs, their windows streamed into the browser. teacher login or demo code