According to the Gregorian Calendar, it was Monday on the date 01/01/01. If any year is input through the keyboard…