CSCI-UA.0002
Python Assignment 2
Due: Wednesday, July 13th
PART ONE:
Your program will be able to tell an NYU student whether s/he will have the
day off for any given day during the academic year 2017-2018. (This is per
the official NYU Calendar: http://www.nyu.edu/registrar/calendars/university-academic-calendar.html#1158)
These are the following NYU Holidays that you should account for during the
Academic year 2017-2018:
- 9/1 (2017) Last Day of Summer Recess
- 9/4 (2017) Labor Day
- 10/9 Academic Holiday
- 11/23 - Thur. - 11/26 Sun. -- Thanksgiving
- Winter recess December 25 (2017) - Jan. 19 (2018)
- Presidents' Day: February 19
- Spring recess Mon. - Sun. March 12 - 18
- Memorial Day: May 18
- Independence Day: Wednesday, July 4
- August 10 - August 31(2018): summer recess
Here is how it should work: First, you should prompt the user to enter an
integer for the month and an integer for the day in question. (For example,
entering "2" for
the month and "20" for the day would
represent February 20th.). (Note that we start
the year on Sept.1 - that should be assumed to be 2017. Note that we END the
year on August 31 - that should be assumed to be 2018.)
Hints:
- The program should check to be sure that the month and day that
the student enters are valid and tell the user if they are not. For
example, "April 31" is not a valid entry.
- The program should make sure that the user provides a date within the correct
range (09/01 - 08/31) and tell the user if they picked a date outside
of the dates under consideration.
- Some NYU vacations stretch out over multiple days.
- Your program should make sure that the numbers that you work with are integers.
Notes about your program:
- Make sure your program includes a comment at the beginning with your name along with a brief synopsis of the program.
- You should use comments throughout the source code to explain key steps and calculations.
- Choose intuitive names for variables
- You should use blank lines where appropriate to make your program easy to read.
- Make sure that your program does not contain any syntax errors.
- Test your program to be sure that it runs the way that you expect.
PART TWO:
-
When you are done and have tested it, post your source file "smithjoe_assign2.py"
to "NYU Classes".