Basic Math
Variables
Flow Control
General Python
String Operations
100
This character denotes the division operator.
What is the forward slash (/) ?
100
This common variable type stores letters, numbers, and symbols.
What is a string?
100
This often used statement checks the validity of a statement before creating a branch.
What is an 'if' statement?
100
To comment a line in Python, you use this/these character(s).
What is a pound sign (#) ?
100
This operator "glues" two strings together.
What is the concatenation (+) operator?
200
These characters have the highest order of operation in Python.
What are parenthesis?
200
This variable type stores decimal numbers.
What is a float?
200

In Python, this operator checks if two values are equal.

What is ==?

200
This commonly used Python data structure contains a collection of items referenced by a numeric index.
What is a list?
200

Identify the letter printed from these lines of code: words = "GIS Rules!" print words[4] (hint: index)

What is 'R'?

300

The result of 9 / 5

What is 1.8?

300

This function allows user input text to be assigned to a variable.

What is input()?

300
What is the value of 'x' after the following Python code has completed executing?
x = 100
for n in range(1,5):
x = x*n print x
What is 2400?
300

This data structure stores pairs of keys and values and is created using curly braces.

What is a dictionary?

300

This method returns the number of occurrences of a substring in a string.

What is count()?

400
To raise the number 5 to the power of 8, you must use the power operator. This/These symbol(s) denote the power operator.
What are two asterisks (**) ?
400
Data stored as a string is surrounded by these.
What are quotes?
400

This flow control structure repeatedly executes a block of code as long as a specified condition is true.

What is a while loop?

400
Python will warn on a logic error, but it will warn (and possibly error) on this type of error.
What is a syntax error?
400

This method converts a string to all uppercase letters.

What is upper()?

500
Denoted as '%', this operator returns the remainder of a division operation.
What is the modulus?
500
To determine the variable type of a variable, you would use this function.
What is type()?
500
The following Python code loops forever. What is it missing?
n = 10
while n<100:
print n
What is a increment statement?
500

This method is used to add an item to the end of a list.

What is append()?

500

This method replaces one part of a string with another part. For example, "hello world".replace("world", "there") returns "hello there".

What is replace()?