Hw1

Hw1

Homework 1 – Patterns and Functions

Submission: Submit your solutions to Moodle. (Read the Submission instructions at the bottom of this page before submitting your work.)

Python Style Requirements

For all the Python programs you submit for this homework and all later homework, we expect you to follow the Python Style Requirements document. Please read the document now before you continue. In particular, you must provide comments and docstrings as appropriate.

Problems

  • Problem 0: Reading [5 points; individual] (hw1pr0)
  • Before you start, today’s lab is to be done in pairs! Make sure that you scroll down on this page to understand what that means. Also make sure that you follow the submission guidelines for pairs.
  • There are two parts to this week’s lab:
  • The first part is hw1pr1.py: you’ll gain experience slicing and interacting with Python data.
  • The second part is hw1pr2.py: you’ll write a number of functions, the fundamental building blocks of software.
  • Problem 3: More Function Fun [35 points; pair] (hw1pr3.py)

·         Extra Credit Challenge Problem [up to +10 points; individual or pair]

A Note About Extra Credit Problems

The extra credit challenge problems are totally optional. We provide them for three reasons:

1.    It’s a chance to earn a few more points on each homework.

2.    More importantly, these problems are fun and useful!

3.    Even more importantly, many problems will give you an opportunity to learn something that has not explicitly been covered in class yet.

We strive to keep the required workload in this class to a challenging but reasonable level — we know you have many other classes, not to mention lives. But we also want to give those of you who want (or need!) a little more CS in your lives a chance to work on some additional challenges.

Submission

For each of these problems, you should be sure to name your file as indicated above. Then, you should submit the file to Moodle in the usual way. (Instructions) Please adhere to the following pair work guidelines:

Working in Pairs

For this assignment, you should work on all of the Python parts with one other student.

The reading problem should be completed on your own.

Extra credit challenge problems may be completed individually or in pairs.

Reiterating what you have already been told in class, here are the individual- and pair-work guidelines:

    • When you work individually, the work you submit should be your own. You are encouraged to seek help from CSCI 203 instructors and student teaching assistants. You may also discuss problems with fellow students, but those discussions must not involve one person doing the work for another. The course Syllabus page has more information on appropriate behavior.
    • When you work as a pair, the above guidelines hold for the pair. Added to the above guidelines, the pair should:
      • work in the same physical location at the same computer on the same “physical” file.
      • contribute equally to the work. Each person should understand the work and be able to explain the contribution of their partner.
      • submit work that is their own, just as noted above for individuals.
      • write your partner’s name as a part of the docstring at the top of the program file.
    • When you submit your work that was done through pair programming, both members of the pair:
      • should each submit all work to their individual Moodle accounts.
      • should each include a Moodle “Submission comment” with each pair assignment providing the names of those who worked on the assignment.

You may choose a different partner than your lab partner for the rest of the homework.

If in doubt, don’t hesitate to get in touch with your instructor.

Back to the CSCI 203 home page.