CSE 110 Programming Project
Due:
Tuesday, December 14, at 11:59 PM. Use Blackboard to submit both programs at the same time.
Please include your name in a Java comment at the top of each program.
For this project, you will write and submit two small Java programs:
1.
DayofWeek Calculations
Zeller
ʼ
s congruence
is an algorithm that was developed by the German mathematician Christian Zeller
to calculate the day of the week for a given date. For example, given a month, day, and year, the
algorithm can tell you if that day in history was a Monday, a Tuesday, etc.
The formula is as follows:
where:
h
is the day of the week (0: Saturday, 1: Sunday, 2: Monday, 3: Tuesday, 4: Wednesday, 5: Thursday,
6: Friday)
q
is the day of the month
m
is the month (3: March, 4: April, .
.., 12: December). January is counted as month 13. February is
counted as month 14 of the year.
j
is the century (meaning the year divided by 100)
k
is the year of the century (meaning year %
100
)
All of the numbers in the formula
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
This is the end of the preview.
Sign up
to
access the rest of the document.
 Fall '08
 SHAUNAKPAWAGI
 Calculation, Weekday names, Monday, profit goal

Click to edit the document details