O'Reilly logo

Head First Learn to Code by Eric Freeman

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 6. 5 functions and abstraction: Getting Functional

Image

You already know a lot. Variables and data types and conditionals and iteration—that’s enough to write basically any program you’d ever want to. In fact, a computer scientist would tell you it’s enough to write any program that anyone could ever conceive of. But you don’t want to stop now, because your next step in computational thinking is learning how to create abstractions in your code. That may sound complex, but it’s actually going to make your coding life simpler. Creating abstractions gives you leverage; with abstraction, you can more easily create programs of increasing complexity and power. You can put your code in neat little packages that you can reuse over and over. And you can forget all the nitty-gritty details of your code and to start thinking at a higher level.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required