# Date falling into the interval

Let there be three intervals: from January `1`st to March `8`th, from March `9`th to June `17`th, from June `18`th to December `31`st. Suppose we also have some date containing month and day. Let's determine what period this date falls into:

`let date = '08-20'; if (date >= '01-01' && date <= '03-08') { console.log('1st interval'); } if (date >= '03-09' && date <= '06-17') { console.log('2d interval'); } if (date >= '06-18' && date <= '12-31') { console.log('3d interval'); }`

Given a date containing the month and day. Determine the zodiac sign that this date falls on.

← →
↑
en ru