just a guide how to start please(and a little bit explanation) :-P , (i dont want you to solve my exercise,i know is not right and is unfair,that s why i only ask for a little help),
thank you very match for your time.
''Build an algorithm that calculates the day of the week on which is your birthday every and any year, having as data, the day of the week and date of birth.''
''Take the "original number"
put the candidate "first". equal to the initial "number"
reiterated''
3 replies to this topic
#1
Posted 20 December 2011 - 09:40 AM
|
|
|
#2
Posted 20 December 2011 - 11:27 AM
1. : string entering
20/12/2011-->day/month/year
Date form: 00/00/0000 --> 10 char
20/12/2011-->day/month/year
Date form: 00/00/0000 --> 10 char
type TData = record d, m, y : word; end;2.: Storage
if not length(string)= 10 then repeat string entering TData.y := StrToInt(Copy( string, lenght(string)-4, lenght(string)); Delete( string, lenght(string)-4, lenght(string)); //delete year + / TData.m := StrToInt(Copy( string, lenght(string)-2, lenght(string)); Delete( string, lenght(string)-3, lenght(string)); //delete month + / TData.d := StrToInt(Copy( string, 1, lenght(string));
#3
Posted 20 December 2011 - 11:53 AM
Do you know the algorithm to determine the day of the week of a date?
#4
Posted 21 December 2011 - 03:43 AM
i have to say only this,YOU ARE INGREDIBLE GUYS,THANK YOU.
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users


Sign In
Create Account

Back to top









