diff --git a/subjects/match-cron/README.md b/subjects/match-cron/README.md index ebd835ca..cf26782e 100644 --- a/subjects/match-cron/README.md +++ b/subjects/match-cron/README.md @@ -2,14 +2,12 @@ ### Instructions -Create a function called `matchCron` it takes a valid cron schedule string -and a valid date. \ -It returns true if the date match the pattern +Create a function named `matchCron`, which accepts a valid cron `string`, and a valid `Date`. Your function should return `true` if the pattern matches the `Date`. -> You only have to implement numbers and `*`. \ -> other complex patterns are not required. +> You only need to implement numbers and `*`. +> Other complex patterns are **not** required. -Only valid pattern will be tested. +Only valid patterns will be tested. ### Example @@ -18,7 +16,7 @@ matchCron('9 * * * *', new Date('2020-05-30 18:09:00')) // -> true matchCron('9 * * * *', new Date('2020-05-30 19:09:00')) // -> true matchCron('9 * * * *', new Date('2020-05-30 19:21:00')) // -> false // | | | | | -// | | | | +- Day of the Week (range: 1-7, 1 standing for Monday) +// | | | | +- Day of the Week (range: 1-7, 1 is Monday) // | | | +--- Month of the Year (range: 1-12) // | | +----- Day of the Month (range: 1-31) // | +------- Hour (range: 0-23) @@ -28,4 +26,4 @@ matchCron('9 * * * *', new Date('2020-05-30 19:21:00')) // -> false ### Notions - [crontab.guru](https://crontab.guru/) -- [devdocs.io/javascript/global_objects/date](https://devdocs.io/javascript/global_objects/date) +- [Date](https://devdocs.io/javascript/global_objects/date)