CSCI-UA.0002
Python Assignment 2
Due: Thursday, July 14th
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 2015-2016. (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 2015-2016:
- 9/1 (2015) Last Day of Summer Recess
- 9/7 (2015) Labor Day
- 10/12 Academic Holiday
- 11/25 - Wed. - 11/29 Sun. -- Thanksgiving
- Winter recess December 24 (2015) - Jan. 24 (2016)
- Presidents' Day: February 15
- Spring recess Mon. - Sun. March 14 - 20
- Memorial Day: May 30
- Independence Day: Monday, July 4
- August 17 - August 31(2016): 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 2015. Note that we END the
year on August 31 - that should be assumed to be 2016.)
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".