I was working on something a few weeks ago, and I needed to calculate the day of the week in PHP. I honestly thought it would be too hard. I thought there were too many variables: leap years, non leap years for years divisible by 400, and maybe something else I hadn’t thought of… As …