← All lessons/Getting Started· Lesson 3 of 32

Printing to the console

Use println to print messages and values — your most important debugging tool.

About 5 min

The console

println(value) prints a value to the console — the dark panel that slides up from the bottom of the canvas. It's how you peek at what your code is doing. print(value) does the same thing.

Printing text and numbers.

TIP

When a sketch isn't behaving, sprinkle println(...) calls to print values and find out where things go wrong.

Your turn

Print the exact message Hello, CodeLab! to the console using println.

Hints