Programming assignment

Write a program that takes as input two numerals representing a month (January is represented by 1) and a year, and then prints a calendar for the month in the year specified.

 
February 2006
S M Tu W Th F S
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28
 INVALID INPUT 
X X X X X X X
? ? ? ? ? ? ?
? ? ? ? ? ? ?
? ? ? ? ? ? ?
? ? ? ? ? ? ?
? ? ? ? ? ? ?
 To print the calendar the program needs to determine the name of the month and that can be derived by converting the month number to the appropriate string. The year comes from input. The program needs to determine the day of the week for the first of the month. Use the techniques mentioned in problem 4 on page pages 415.

Assignment is Due Wednesday, March 15, 2006. Deliverables:

02 2004
02 2006
02 2000
02 1900
5 2006
12 1980
13 2006
0 2005
-5 123
12 123
2005 2
13 2006
2 1580
2 1581
2 1582
2 1583
5 1945
5 2945
5 45
5 999999
1 0
10 1492
07 1776



Some warmups
p513 # 12,p 514 #5, p 515 #10, 11

Abstract Data Types, OOP, Classes

Take a look at Time class in Chapter 11

P580 #5, P581 #8, p582 #13, #14, #15, P583 #14

Creative Commons License
This work is licensed under a Creative Commons License.
Ernest Ackermann Department of Computer Science, Mary Washington College
CPSC 220 | CPSC 401

Bibliographic Information:
.