Problem Set 7: C$50 Finance


  1. Watch Week 9’s lecture.

  2. Implement a stock-trading website.

  3. Submit a form.


For help with Week 9 and Problem Set 7:

  • Attend David’s walkthrough on Mon 10/31, 1pm – 2:30pm, in Sanders Theatre.

  • Watch David’s walkthrough herein.

  • Attend a walkthrough during office hours on

    • Wed 11/2 at 9pm in Widener or

    • Thu 11/3 at 9pm in Widener.

  • Attend your TF’s section (or another if you have a conflict).

  • Post questions and search answers in CS50 Discuss.

  • Attend individual TFs' and CAs' office hours at HSA.

  • Attend course-wide office hours.

Academic Honesty

Do keep in mind the course’s policy on academic honesty, particularly its "regret clause."

Getting Started

mkdir ~/workspace/pset7/
cd ~/workspace/pset7/


Implement C$50 Finance in pset7/finance/.


  • Be sure to use Python 3, not Python 2.

  • All code that you write should be consistent with Style Guide for Python Code, otherwise known as PEP 8.

  • Insofar as a goal of this problem set is to teach you how to teach yourself a new language, keep in mind that these acts are not only reasonable, per the syllabus, but encouraged toward that end:

    • Incorporating a few lines of code that you find online or elsewhere into your own code, provided that those lines are not themselves solutions to assigned problems and that you cite the lines' origins.

    • Turning to the web or elsewhere for instruction beyond the course’s own, for references, and for solutions to technical difficulties, but not for outright solutions to problem set’s problems or your own final project.

How to Submit

Step 1 of 2

cd ~/workspace/pset7/finance/
submit50 pset7

Step 2 of 2

This was Problem Set 7.