# Getting Around The Book¶

## ActiveCode Windows¶

One of the most important things that you can do when you are learning a programming language is to write programs. Unfortunately, typical textbooks allow you to read about programming but don’t allow you to practice. We have created a unique tool called ActiveCode that allows you to write, modify, and execute programs right in the text itself (right from the web browser). Although this is certainly not the way real programs are written, it provides an excellent environment for learning a programming language like Python since you can experiment with the language as you are reading.

Take a look at the ActiveCode interpreter in action. If we take a simple Python program and make it active, you will see that it can be executed directly by pressing the Run button. Try pressing the Run button below.

## The CodeLens Tool¶

In addition to ActiveCode, you can also execute Python code with the assistance of a unique visualization tool. This tool, known as CodeLens, allows you to control the step by step execution of a program. It also lets you see the values of all variables as they are created and modified. The following example shows CodeLens in action on the same simple program as we saw above. Remember that in ActiveCode, the source code executes from beginning to end and you can see the final result. In Codelens you can see and control the step by step progress. Try clicking on the Forward button below.

(firstexample)

## Self-Check Questions¶

Finally, it is also possible to embed simple questions into the text. These questions provide a way for you to check yourselves as you go along. The questions also provide feedback so that you can understand why an answer may or may not be correct.

        sc-1-1: Construct a block of code that correctly implements the accumulator pattern.x = 0