May 2018
Intermediate to advanced
256 pages
6h 20m
English

As your programs become more sophisticated, you might want to reuse code you’ve already written to save time. Fortunately, you can reuse your code as a module, which is a program that contains functions that other programs can call.
In this chapter, you’ll learn how to create custom functions and your own module. The turtles will need to run these functions in Chapter 8, so you’ll write functions your tree farmer turtles (and the turtles you make in later chapters) will load as a module.
To create your own functions, you use a function statement, which is made ...
Read now
Unlock full access