This defines the following concepts from computing:
Arithmetic Expression - An arithmetic expression contains a mathematical operator like - for subtraction or * for multiplication.
Assignment - Assignment means setting a variable’s value. For example, x = 5 assigns the value of 5 to a variable called x.
Assignment Dyslexia - Assignment Dyslexia is putting the variable name on the right and the value on the left as in 5 = x. This is not a legal statement.
Camel-Case - Camel-case is when the first letter of each additional word is uppercased when you create variable names that have several words in them like firstName.
Integer Division - Integer division is when you divide one integer by another. In some languages this will only give you an integer result.
Mixed-Case - Mixed-case means using upper and lower case letters in a variable name like "HI There". One way to do this is to use camel-case.
Modulo - The modulo, or remainder operator, %, returns the remainder after you divide one value by another. For example the remainder of 3 % 2 is 1 since 2 goes into 3 one time with a remainder of 1.
Tracing - Tracing a program means keeping track of the variables in the program and how their values change as the statements are executed. We used a Code Lens tool to do this in this chapter.
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.
Append - You can add two strings together using the + symbol. This is also called concatenate.
Capitalize - The capitalize function returns a new string with the first character capitalized.
Concatenate - You can use + to concatenate (append) two strings like this string3 = string1 + string2. This will create a new string called string3 with all the characters from the first string, string1, followed by all the characters in the second string, string2.
Function - A function returns a value. Function can take input as well, but don’t have to. An example is the string lower() function that returns a string with all lowercase letters.
Immutable - Immutable means that it does not change. Strings are immutable in Python. When you call a function that appears to change a string, it will actually return a new string.
Index - An index is a number associated with the position of a character in a string. In Python the first character in a string is at index 0.
Object - An object can have behavior (things it can do). For example a turtle object can go forward a specified amount. Strings and turtles are objects in Python.
String - A string is a sequence of characters. You specify a string as characters inside a pair of single, double, or triple quotes.
Substring - A substring is a part of a string. One substring of “Hi there” would be “Hi”.
Body Syntonic - Body syntonic means experiences related to knowledge of your body. You can use your knowledge of how to move your body to help you understand how to move the turtle objects.
Comment - A comment describes one or more lines of code. Comments are ignored by the computer. A comment in Python starts with #. The computer will ignore everything from the start of the comment to the end of that line.
Procedure - A procedure does an action, but doesn’t return a value. An example of a procedure is forward(100) which makes the turtle go forward by 100 pixels.
Post a Comment
0Comments