This data type represents sequences of characters.
What is string?
The keyword for string.
Command to get and store a user's name
(answers may vary)
name = input("What's yr name?")?
What platfrom are we coding in?
What is Pickcode?
The name of the input a function will receive.
Ex: numSides is the ______ in
polygon(numSides)
What is parameter?
This data type is used for whole numbers and their opposites.
What is integer?
The keyword for integer.
What is int?
Command to pause the program for 5 seconds.
What is time.sleep(5)
If you get this error:
SyntaxError: unexpected EOF while parsing
You are probably missing...
What is "parentheses"
The specific value of a parameter.
Ex: The value 5 is the ____for numSides
polygon(numSides) --> polygon(5)
What is argument?
This data type is used for fractional (decimal) values.
What is float?
The keyword for Boolean.
What is bool?
Expression that would calculate how many eggs are left over after packaging 9837 eggs in dozens.
What is
9837 % 12
?
If you get this error:
NameError: name 'random' is not defined
You are probably missing...
What is an import statement?
The fancy word for joining strings and other data types in a print statement.
What is concatenation?
This data type has only two values, True or False.
What is Boolean?
Keyword for getting user info from the keyboard.
What is input?
Command to output the result of
5^2 + 2(7) + 9
(Nothing else)
print(5**2 + 2*7 + 9)
Command that would allow you to take in a price from the user (like 1.50)
(answers may vary)
price = float(input("What is the price of a donut")
The operation that gives the remainder of a division problem.
What is modulus?
This data type is used to deal with imaginary numbers.
(Yup, wasn't covered...)
What is complex?
Keyword to bring in functionality besides the basic Python package, like random numbers or special math operations.
What is import?
Command to output the square root of 7987 in a sentence starting "Sq rt of 7987 is..."
What is
print("Sq rt of 7987 is " + str(math.sqrt(7987))
What does IDE stand for?
Integrated Development Environment
The word for turning one data type into another.
Ex:
age = int(input("How old are you?")
print(str(age) + "is a fine age.")
What is casting?