Course of Raku / Advanced / More about built-in types / Date and time / Exercises

Day of the week

Problem

Print True if Valentine’s Day, the 14th of February 2027, falls on a weekend (Saturday or Sunday), and False otherwise. Recall that day-of-week numbers the days from 1 for Monday to 7 for Sunday.

Example

The program prints:

True

Solution

See the solution

Course navigation

Solution: One week later   |   Solution: Day of the week