Before you keep reading...
Runestone Academy can only continue if we get support from individuals like you. As a student you are well aware of the high cost of textbooks. Our mission is to provide great books to you for free, but we ask that you consider a $10 donation, more if you can or less if $10 is a burden.
Before you keep reading...
Making great stuff takes time and $$. If you appreciate the book you are reading now and want to keep quality materials free for other students please consider a donation to Runestone Academy. We ask that you consider a $10 donation, but if you can give more thats great, if $10 is too much for your budget we would be happy with whatever you can afford as a show of support.
Chapter 1 - Concept Summary¶
Chapter 1 included the following concepts from computing.
Code - Code is a set of instructions that a computer can understand. This is sometimes called a program.
Comment - Comments explain what we’re doing in the programs and are intended to be read by people, not computers. In Python a comment starts with
#. The computer will ignore everything from the start of the comment to the end of that line.
Dot-Notation - Dot-notation is how you ask an object to do something in Python. You use the name of the object followed by a dot (period) and then followed by what you want it to do and then any values in parentheses. For example to return a new string will all lowercase letters from a variable called
sentence.lower(). To ask a turtle named
alexto go forward 50 units use
Library - A library is a group of programs that provides some functionality. The
Turtlelibrary is a good example. It lets us create and work with
Pixel - A pixel is one small part (element) of a picture. Pixels are stored in a grid and have both x (horizontal) and y (vertical) values. A pixel has a color which can be defined by an amount of red, green, and blue with values from 0 to 255.
Program - A program is a set of instructions that a computer can understand to accomplish some goal. This is sometimes called code.
Screen - A
Screenis part of the Turtle library. It is a space on the page for the turtle to move in and draw on.
String - A string is anything we can type between a pair of pair of single quotes (
'Hi'), double quotes (
"Hi"), or triple quotes (
'''Hi'''). It is a sequence of characters.
Variable - A variable is a name associated with computer memory that can hold a value and that value can change or vary. One example of a variable is the score in a game.
This is the end of chapter 1. We would love it if you could give us some feedback on this chapter at https://www.surveymonkey.com/r/ch1-teacher-fb. You might want to open this link in a new tab to make it easier for you to return to your place in this ebook.