// Click on the image to give it focus,
// and then press any key.
var value = 0;
function draw() {
fill(value);
rect(25, 25, 50, 50);
}
function keyPressed() {
if (value == 0) {
value = 255;
} else {
value = 0;
}
}