- Slide deck: https://zipcoder.github.io/reveal-slides.data-engineering/zcw_content/python/fundamentals-part1.html
- Metric Conversion charts: https://www.metric-conversions.org/
- Open Terminal.
- Launch the Python interpreter.
- Print a line that says "Hello Python".
- Exit the Python interpreter.
- Using the Python interpreter, identify the data type for the following values:
- True
- 42
- False
- 1.5
- "Python is fun"
- "3.5"
- Using the Python interpreter, perform the following operations. Be sure to experiment with mixing intergers and floats.
- Addition
- Subtraction
- Multiplication
- Division
- Floor division
- Modulo
- Exponentiation
Create a Python script called first_name_500_times.py. Modify your script according to the instructions below.
- Declare a variable called first_name with your first name as its value.
- Print the value of first_name to the screen 500 times.
- Save & execute the script.
- Using Terminal, make a copy of first_name_500_times.py and call it full_name.py
cp first_name_500_times.py full_name.py
Modify full_name.py according to the instructions below.
- Comment out the line where your first name was printed 500 times.
- Create a variable called last_name with your last name as its value.
- Create a variable called full_name whose value is the combination of the first_name variable and the last_name variable.
- Print the value of the full_name variable.
Create a Python script called fahrenheit_to_celsius.py
- The script should declare a variable called fahrenheit.
- The script should then convert the value of fahrenheit to celsius.
- The conversion should be displayed on the screeen in the following format: "32 degrees fahrenheit is equal to 0.0 degree(s) celsius"