Lab 1 - Getting started with Python - (50 points)
Due date: 2/6/2019 at 11:59pm
Objectives
- Familiarize yourself with the Python syntax
- Learn about variables
- Familiarize yourself with basic command line operation and submission
Product of the first five positive integers (5 points)
Write a Python program (product.py) that prints the result of multipling the first five positive integers starting at 1.
Practice with print (15 points)
Write a program (house.py) that prints a house that looks exactly like the following
+ + + + + +-----+ | .-. | | | | | +-+-+-+
Practice with Integers (30 points)
Write a program (integeroperations.py) that prompts the user for two integers and then prints
- The difference
- The product
- The average
- The distance (absolute value of the difference) - Use the abs() function
- The maximum (the larger of the two) - Use the max() function
- The minimum (the smaller of the two) - Use the min() function
Submitting the lab using Canvas
Upload the following files to Canvas:
- product.py
- house.py
- integeroperations.py
- README file - A description of your lab with your name and your student ID. Please include any problems you faced, any resources you used, names of friends/tutors you received help from.