Hello World! Third Edition

Book description

Hello World! Computer Programming for Kids and Other Beginners, Third Edition introduces the world of computer programming in a clear and fun style using Python, a programming language designed to be easy to learn.



About the Technology

Learn to talk to your computer in its own language! Whether you want to create a game, start a business, or solve an important problem, the first step is learning to write your own programs.



About the Book

Hello World! Computer Programming for Kids and Other Beginners, Third Edition introduces the world of computer programming in a clear and fun style. Using Python, a programming language designed to be easy to learn, each engaging lesson teaches skills that apply to any kind of programming. It brings to life the basic concepts of computing—looping, decisions, input and output, graphics, and more.

Written by father-and-son team Warren and Carter Sande, this international bestseller is kid-tested and reviewed by professional educators. Now in its third edition, Hello World! has been fully updated to Python 3 and includes a new chapter about how the internet works.



What's Inside

  • Colorful pictures, clever cartoons, and fun examples
  • Practice questions and exercises
  • Updated to Python 3


About the Reader

You don’t need to know anything about programming to use the book. If you can open an app and save a file, you’re ready to go!



About the Authors

Warren Sande is an electronic systems engineer who uses Python as his favorite “do anything” scripting language at work, and also uses it to help teach people about computers and programming. Carter Sande started programming when he was six years old, wrote the first edition of this book with his dad when he was nine, and now works as a professional software engineer. In his spare time, he creates games for retro consoles like the Game Boy Advance and enjoys reading and writing interactive fiction.

Illustrated by Martin Murtonen.



Quotes
A highly engaging approach that introduces kids to programming using Python.
- Ben McNamara, DataGeek

Highly recommended...learn computer programming in a simple, enjoyable, and entertaining format.
- Bob Dust, Reynolds Community College

A lightweight and delightful approach to learning programming for parents and kids alike. The illustrations and side comments add great perspectives to the subject matter.
- Eli Hini, Venovia

Simple yet empowering. Kids will be amazed at how quickly they can get productive.
- James McGinn, Bull Valley

Publisher resources

View/Submit Errata

Table of contents

  1. Copyright
  2. Brief Table of Contents
  3. Table of Contents
  4. Praise for the First Edition of Hello World!
  5. Praise for the Second Edition of Hello World!
  6. Preface
    1. What is programming?
    2. Python—a language for us and the computer
    3. Why learn programming?
    4. Why Python?
  7. Acknowledgments
    1. Acknowledgments for the First Edition
    2. Acknowledgments for the Second Edition
    3. Acknowledgments for the Third Edition
  8. About this book
    1. What you need
    2. What you don’t need
    3. Carter says
    4. What’s new in the Third Edition
    5. Note to parents and teachers
  9. Chapter 1. Getting Started
    1. Installing Python
    2. Starting Python with IDLE
    3. Instructions, please
    4. Interacting with Python
    5. Time to program
    6. Running your first program
    7. If something goes wrong
    8. Our second program
  10. Chapter 2. Remember This: Memory and Variables
    1. Input, processing, output
    2. Names
    3. What’s in a name?
    4. Numbers and strings
    5. How “variable” are they?
    6. The new me
  11. Chapter 3. Basic Math
    1. The four basic operations
    2. Operators
    3. Order of operations
    4. Integer division: Quotient and remainder
    5. Exponentiation: Raising to a power
    6. Increment and decrement
    7. Really big and really small
  12. Chapter 4. Types of Data
    1. Changing types
    2. Getting more information: type()
    3. Type-conversion errors
  13. Chapter 5. Input
    1. input()
    2. Putting the input on the same line
    3. Inputting numbers
    4. Input from the web
  14. Chapter 6. GUIs: Graphical User Interfaces
    1. What’s a GUI?
    2. Our first GUI
    3. GUI input
    4. Pick your flavor
    5. The number guessing game ... again
    6. Other GUI pieces
  15. Chapter 7. Decisions, Decisions
    1. Testing, testing
    2. Indenting
    3. Am I seeing double?
    4. Other kinds of tests
    5. What happens if the test is false?
    6. Testing for more than one condition
    7. Using and
    8. Using or
    9. Using not
  16. Chapter 8. Loop the Loop
    1. Counting loops
    2. Using a counting loop
    3. A shortcut: range()
    4. A matter of style: Loop variable names
    5. Counting by steps
    6. Counting without numbers
    7. While we’re on the subject ...
    8. Bailing out of a loop: break and continue
  17. Chapter 9. Just for You: Comments
    1. Adding comments
    2. Single-line comments
    3. End-of-line comments
    4. Multiline comments
    5. Triple-quoted strings
    6. Commenting style
    7. Comments in this book
    8. Commenting out
  18. Chapter 10. Game Time
    1. Skier
  19. Chapter 11. Nested and Variable Loops
    1. Nested loops
    2. Variable loops
    3. Variable nested loops
    4. Even more variable nested loops
    5. Using nested loops
    6. Counting calories
  20. Chapter 12. Collecting Things Together: Lists and Dictionaries
    1. What’s a list?
    2. Creating a list
    3. Adding things to a list
    4. Getting items from a list
    5. “Slicing” a list
    6. Modifying items
    7. Other ways of adding to a list
    8. Deleting from a list
    9. Searching a list
    10. Looping through a list
    11. Sorting lists
    12. Mutable and immutable
    13. Lists of lists: Tables of data
    14. Dictionaries
  21. Chapter 13. Functions
    1. Functions: The building blocks
    2. Passing arguments to a function
    3. Functions that return a value
    4. Variable scope
    5. A bit of advice on naming variables
  22. Chapter 14. Objects
    1. Objects in the real world
    2. Objects in Python
    3. Object = attributes + methods
    4. Creating objects
    5. An example class: HotDog
    6. Hiding the data
    7. Polymorphism and inheritance
    8. Thinking ahead
  23. Chapter 15. Modules
    1. What’s a module?
    2. Why use modules?
    3. How do we create modules?
    4. How do we use modules?
    5. Namespaces
    6. Standard modules
  24. Chapter 16. Graphics
    1. Getting some help: Pygame
    2. A Pygame window
    3. Drawing in the window
    4. Individual pixels
    5. Images
    6. Let’s get moving!
    7. Animation
    8. Smoother animation
    9. Bouncing the ball
    10. Wrapping the ball
  25. Chapter 17. Sprites and Collision Detection
    1. Sprites
    2. Bump! Collision detection
    3. Counting time
  26. Chapter 18. A New Kind of Input: Events
    1. Events
    2. Keyboard events
    3. Mouse events
    4. Timer events
    5. Time for another game—PyPong
  27. Chapter 19. Sound
    1. More help from Pygame: mixer
    2. Making sounds vs. playing sounds
    3. Playing sounds
    4. Controlling volume
    5. Playing background music
    6. Repeating music
    7. Adding sounds to PyPong
    8. Adding music to PyPong
  28. Chapter 20. More GUIs
    1. Working with PyQt
    2. Qt Designer
    3. Saving the GUI
    4. The return of event handlers
    5. More useful GUIs
    6. TempGUI
    7. Creating the new GUI
    8. Squashing a bug
    9. What’s on the menu?
  29. Chapter 21. Print Formatting and Strings
    1. New lines
    2. Horizontal spacing: Tabs
    3. Inserting variables in strings
    4. Number formatting
    5. Formatting, the new way
    6. Strings ‘n’ things
  30. Chapter 22. File Input and Output
    1. What’s a file?
    2. Filenames
    3. File locations
    4. Opening a file
    5. Reading a file
    6. Text files and binary files
    7. Writing to a file
    8. Saving your stuff in files: pickle
    9. Game time again—Hangman
  31. Chapter 23. Take a Chance: Randomness
    1. What’s randomness?
    2. Rolling the dice
    3. Creating a deck of cards
    4. Crazy Eights
  32. Chapter 24. Computer Simulations
    1. Modeling the real world
    2. Lunar Lander
    3. Keeping time
    4. Time objects
    5. Virtual Pet
  33. Chapter 25. Skier Explained
    1. The skier
    2. The obstacles
  34. Chapter 26. Making Network Connections with Sockets
    1. What’s the difference between text and bytes?
    2. Servers
    3. Getting data from the client
    4. Making a chat server
  35. Chapter 27. What’s Next?
    1. For younger programmers
    2. Python
    3. Game programming and Pygame
    4. Other game programming (non-Python)
    5. Keep it BASIC
    6. Websites
    7. Mobile apps
    8. Look around
  36. Appendix A. Variable Naming Rules
  37. Appendix B. Differences Between Python 3 and 2
    1. print
    2. input()
    3. Integer division
    4. range()
    5. Bytes and character encodings
    6. Python 2 to 3 conversion
  38. Appendix C. Answers to Self-Test Questions
    1. Chapter 1: Getting Started
    2. Chapter 2: Remember This: Memory and Variables
    3. Chapter 3: Basic Math
    4. Chapter 4: Types of Data
    5. Chapter 5: Input
    6. Chapter 6: GUIs: Graphical User Interfaces
    7. Chapter 7: Decisions, Decisions
    8. Chapter 8: Loop the Loop
    9. Chapter 9: Just for You—Comments
    10. Chapter 10: Game Time
    11. Chapter 11: Nested and Variable Loops
    12. Chapter 12: Collecting Things Together—Lists and Dictionaries
    13. Chapter 13: Functions
    14. Chapter 14: Objects
    15. Chapter 15: Modules
    16. Chapter 16: Graphics
    17. Chapter 17: Sprites and Collision Detection
    18. Chapter 18: A New Kind of Input: Events
    19. Chapter 19: Sound
    20. Chapter 20: More GUIs
    21. Chapter 21: Print Formatting and Strings
    22. Chapter 22: File Input and Output
    23. Chapter 23: Take a Chance—Randomness
    24. Chapter 24: Computer Simulations
    25. Chapter 26: Making Network Connections with Sockets
  39. List of Code Listings
  40. ANOTHER TITLE FROM MANNING
  41. Index
  42. List of Tables
  43. List of Listings

Product information

  • Title: Hello World! Third Edition
  • Author(s): Carter Sande, Warren Sande
  • Release date: December 2019
  • Publisher(s): Manning Publications
  • ISBN: 9781617297021