What's a value? →
A value is just data!
What's a type? →
A type is just a kind or category of values. Name the types that we learned about. →
str - strings
What's a string? How do we know a literal value is a string? →
Name two operators that can be used with strings →
What do the following lines of code output (error is a possible answer)? →
int - integers
What's an int? →
float - floating point numbers
What's a float? How do we know a literal value is a float? →
Name 7 operators that can be used on floats and/or ints. →
The following block of code will cause a run time error. Why? →
A Type Error will occur… the operator, plus, doesn't support int and str. What can be done to fix this? →
One fix is to convert the variable, a, into an integer using the int function:
Name three functions that can be used to convert a value from one type to another. →
The following functions will attempt to convert the parameter(s) passed in into the type that the function is named after:
Variables allow us to bind names to values so that the variable name can be used in place of the literal value. In code, how would we assign the value 12 to a variable called n? →