Review the pre-lab shell examples.
Work on this lab with your partner (or on your own if you have not been assigned one).
Reminder: test your work as you go!
Show your work for a given problem to the instructor or one of the lab assistants before moving on to the next problem, but do not get too bogged down on any one problem.
In the common case, you will not complete the exercises during our scheduled lab. It is then up to you to complete the lab on your own time.
Rename your file to have both your names in it as:
lab7_alpha_beta.py
(if your names were Alpha and
Beta).
Email me a copy of your work (attach your version of the
lab7
file - named as just indicated) by replying to the
email that officially announces the lab. If working with a lab partner
send me just one copy for the pair, but CC your partner.
Download and unzip the starter archive.
Use IDLE to open lab7_examples.py
in the
lab7
. Read the functions defined in that file and
experiment with using them.
Included in the lab7
folder is a runnable solution
module called lab7x.py
. You can use it to see the result of
executing the solution version of any of the assigned exercises. After
running either lab7_examples.py
or lab7.py
as
a module in IDLE, you can import lab7x
and access the
solution versions in the IDLE shell as follows:
>>> import lab7x
>>> lab7x.count_less_more((47, 63, 2, 34, 19), 50)
(4, 1)
If one of the exercises you are working on requires the solution to a previous exercise that you have not yet completed, you can use the solution version.
Use IDLE to open lab7.py
in the lab7
folder.
Remove the starter comment line in that file.
Replace <YOUR NAME(s) GO HERE>
with your
name(s).
Save as you go.
Run the module in IDLE, test your functions in the IDLE shell.