Test
Looking for information about the test itself, including past problems, the review sessions, and advice?
This test is open-book: you may use any and all non-human resources during the test, but the only humans to whom you may turn for help or from whom you may receive help are the course’s heads, which means that
you may
- browse and search the internet,
- review books,
- review questions and answers already posted on Ed,
- review the course’s own materials,
- use VS Code,
- email the course’s heads at heads@cs50.harvard.edu with questions, but
you may not
- provide help to anyone or
- receive or solicit help from anyone other than the course’s heads.
Take care to review the course’s policy on academic honesty in its entirety. Note particularly, but not only, that
- looking at another individual’s work during the test is not reasonable and
- turning to humans (besides the course’s heads) for help or receiving help from humans (besides the course’s heads) during the test is not reasonable.
Unless otherwise noted, you may call any functions we’ve encountered this term in code that you write. You needn’t comment code that you write, but comments may help in cases of partial credit. If having difficulty with code, you may resort to pseudocode for potential partial credit.
Among the test’s aims is to assess your newfound comfort with the course’s material and your ability to apply the course’s lessons to familiar and unfamiliar problems. And most problems aspire to teach something new. Be sure to click (and learn from) any links or videos included in problems.
You may resubmit as many times as you would like before the test’s deadline. Late submissions incur penalties per the course’s syllabus.
What To Do
-
Accept the test assignment via GitHub Classroom.
-
In VS Code, execute
get50 test
to download the distribution code for the test.
-
Run
update50
in your Codespace and, if prompted, click rebuild now. -
Open the test’s response document in Google Docs.
-
Make a copy of the response document in your own Google account by choosing File > Make a Copy.
-
Solve all of the problems below, in any order, by writing your answers in the response document, replacing each TODO with an answer. Some questions will instead ask you to complete a TODO in one of the files in your
test
directory within VS Code.
Problems
- Checking Speller
- Code Reviews
- Duo Mobile
- Emojicode
- Harvard Pep Squad
- Imagineering
- International Obfuscated C Code Contest
- Reinventing Some Wheels
- View Source
- XCheck
CHANGELOG
Reload this page (and each problem’s page) throughout the week to see any clarifications to the test.
- 2021-11-16
- Clarified “all-lowercase” suffices in XCheck.
- Changed 2 columns of spaces between letters to 1 column of spaces in Harvard Pep Squad.
- 2021-11-17
- Clarified that “output” means “print” in Harvard Pep Squad.
- 2021-11-27
- Added parentheses for sample solution’s sake.
How to Submit
-
Before submitting, download a ZIP file of your
test
folder (which should contain foldersemojicode
,squad
, andwheels
). First, ensure you are in your test directory by runningcd
followed by
cd test
Make sure your terminal prompt looks like the below:
test/ $
Then, run the following command:
zip -r test.zip * -x "*x86_64*"
The
-x "*x86_64*"
argument is intended to exclude any system files you may have downloaded to installemojicodec
for Emojicode. - Control-click or right-click on your
test.zip
file in VS Code’s file browser and choose Download. - Go to CS50’s Gradescope page.
- Click Test: Code Files.
- Drag and drop your
test.zip
file to the area that says “Drag & Drop”. - Click “Upload”.
- You should see a message that says “Test: Code Files submitted successfully!” Not to worry if you see 0/31 points—the autograder will not be configured until after the test’s deadline.
- Download your completed test response document from Google Docs as a PDF by choosing File → Download → PDF Document, and save it to your computer.
- Go to CS50’s Gradescope page.
- Click Test: Response Document.
- Click Submit PDF.
- Click Select PDF and choose your test file.
- Click Upload PDF.
- For each question in the Question Outline at left, click on the question and then click on the page (or pages) on which your response to that question is located. Since some questions (Reinventing Some Wheels, Harvard Pep Squad, and parts of Emojicode) do not involve written answers, it is okay to leave pages for those questions unassigned.
- Click Submit.
- You should see a message that says “Test: Response Document submitted successfully!” You may need to first confirm that you have not assigned all pages to all questions.
You are welcome to resubmit your code files and response document up until the deadline. Only your last submission will be taken into consideration.
If you run into any trouble with the above steps, email heads@cs50.harvard.edu!