|
|||
Following the Passing TimeWrite a function that takes a string as a parameter containing a time of the week in the following format: dayname_abbreviation hour.min The dayname_abbreviation is one of „H”, „K”, „Sze”, „Cs”, „P”, „Szo”, „V”. (These days appear in the traditional Hungarian order of weekdays, but with their Hungarian abbreviations: H – „Monday”, K – „Tuesday”, Sze – „Wednesday”, Cs – „Thursday”, P – „Friday”, Szo – „Saturday”, V – „Sunday”.) The time is in 24-hour format, i.e., hour is between 0–23, and min is between 0–59. The function should determine and return the number of minutes elapsed between the beginning of the week and the specified time of the week, assuming that the week starts on Monday at 0.00 and that there is no change in daylight saving time set for the week. The specification of the function
Note
Place the function in a file named
|
|||
University of Debrecen; Faculty of Informatics; v. 09/30/2024 |