Summary + Submission¶
Take Heart
We’ve covered a lot of ground in this lab! If this is your first experience with programming, it is common to feel a little overwhelmed. It may be helpful to think of programming as a foreign language: you will improve little by little as you get used to the vocabulary and grammar through reading code examples and writing your own code. Programming literacy comes over time and through repetition.
Key Concepts¶
These are the main topics covered in this lab.
Python executes a set of instructions one line at a time.
Variables store information, such as numbers or letters, to be used later. Use
=to create a variable.A function is a coding recipe used to do small tasks that get used more than once. Functions are defined with
def, end withreturn, and are called with parentheses,func().Program behavior can be controlled with
if/elseclauses. Usingandandoroperators is helpful for specifying more complex control flows.
Submitting the Lab¶
After completing this lab, check your code for errors.
In the
Runtimemenu at the top of Google Colab, selectRestart session and run all.If any of the cells produce error messages, fix the error(s).
Repeat steps 1 and 2 until there are no error messages. Your code cannot be graded if there are any error messages.
Next, in the File menu on Google Colab select Download > Download .ipynb.
The downloaded file can be uploaded to gradescope.com for grading.