Home >Backend Development >PHP Tutorial >PHP gets the date of every Saturday, PHP determines odd and even numbers
Description of requirements: Determine whether it is a bi-weekly or single-week holiday based on the date of every Saturday. That is, if the date on Saturday is an odd number, then this week is an odd-week holiday; if it is an even number, it is a double-week holiday. Before, we did not take into account the issue of the different number of days in each month, resulting in an inaccurate judgment. After modification, it is now accurate. Example, PHP gets the date of every Saturday and PHP determines odd and even numbers implementation code.
|