CTK Exchange
Front Page
Movie shortcuts
Personal info
Awards
Reciprocal links
Terms of use
Privacy Policy

Interactive Activities

Cut The Knot!
MSET99 Talk
Games & Puzzles
Arithmetic/Algebra
Geometry
Probability
Eye Opener
Analog Gadgets
Inventor's Paradox
Did you know?...
Proofs
Math as Language
Things Impossible
My Logo
Math Poll
Other Math sit's
Guest book
News sit's

Recommend this site

Manifesto: what CTK is about |Store| Search CTK Buying a book is a commitment to learning Table of content Things you can find on CTK Chronology of updates Email to Cut The Knot Recommend this page

CTK Exchange

Subject: "problem solving. CRitical thinking"     Previous Topic | Next Topic
Printer-friendly copy     Email this topic to a friend    
Conferences The CTK Exchange Middle school Topic #60
Reading Topic #60
Gary
guest
Feb-06-02, 10:39 PM (EST)
 
"problem solving. CRitical thinking"
 
   A programmer is making a program that will create calenders. The Program will contain calendar pages with just the days of the week and the dates, no months. The user will insert the name of the month before printing the calendar. It a page will exist for every arrangement of dates in a month, how many pages will need to be designed?


  Alert | IP Printer-friendly page | Edit | Reply | Reply With Quote | Top
alexb
Charter Member
1122 posts
Feb-06-02, 11:03 PM (EST)
Click to EMail alexb Click to send private message to alexb Click to view user profileClick to add this user to your buddy list  
1. "number of calendar pages"
In response to message #0
 
   And how the pages will be different?


  Alert | IP Printer-friendly page | Edit | Reply | Reply With Quote | Top
Laocon
Member since Jan-18-02
Feb-07-02, 07:07 AM (EST)
Click to EMail Laocon Click to send private message to Laocon Click to add this user to your buddy list  
2. "RE: number of calendar pages"
In response to message #1
 
   "30 days hath September..."

Work out how many month-types there are (grouping by the number of days).

eg MONTH TYPE 1 = 30 day-month = September, April, June, November

Each month type, must begin on one of seven days.

Now multiply MONTH TYPES * 7...

OR...

There is a formula for working out the day of the week from the date. You could try incorporating that somehow.


  Alert | IP Printer-friendly page | Edit | Reply | Reply With Quote | Top
Jack Wert
guest
Feb-07-02, 09:10 PM (EST)
 
3. "RE: number of calendar pages"
In response to message #2
 
   You did not state the format for the days and dates. Would it be a series of rows of seven days, starting, say, with Sundays"? If so, I think Laoconís response is valid: 4*7 layouts for the 30 day months, 4 layouts for the 28 day months, 4 layouts for the leap year 29 day months, and 7*7 layouts for the 31 day months.

Then, as Laocon suggested, there is a way to equate the year with the day on which 01 January falls. The rest could than be related to that for any given year. The proper layout for any month could then equate to that start, the starting day being "x" days later in the year. If I remember correctly, the only other correction occurs only every 200 years or so, and that is therefore not a consideration for current calendar constructions.

Jack


  Alert | IP Printer-friendly page | Edit | Reply | Reply With Quote | Top
amit
guest
Nov-12-03, 07:30 PM (EST)
 
4. "CRitical thinking"
In response to message #0
 
   Say we start with jan, first index will say day and second no. of days
Jan - (0,31)
Feb - (3,28)
Mar - (3,31)
Apr - (6,30)
May - (1,31)
Jun - (4,30)
Jul - (6,31)
Aug - (2,31)
Sep - (5,30)
Oct - (0,31)
Nov - (3,30)
Dec - (5,31)
Only Jan and Oct are same. so in total there will be 11*7 = 77 Pages.


  Alert | IP Printer-friendly page | Edit | Reply | Reply With Quote | Top

Conferences | Forums | Topics | Previous Topic | Next Topic

You may be curious to have a look at the old CTK Exchange archive.
Please do not post there.

|Front page| |Contents|

Copyright © 1996-2018 Alexander Bogomolny

66596489