๐๐ฎ๐๐ฎ๐ฆ๐ฐ๐ฟ๐ถ๐ฝ๐ ๐๐ผ๐ฑ๐ถ๐ป๐ด ๐๐ผ๐ด๐ถ๐ฐ
Master basic JavaScript logic. Use these loops to handle numbers.
Know your equality operators.
- Use == for loose equality. It converts types.
- Use === for strict equality. It checks value and type.
Find numbers divisible by 3 and 5.
- Loop from 1 to 100.
- Use the && operator.
- This finds numbers where both conditions are true.
Find numbers divisible by 3 or 5.
- Loop from 1 to 30.
- Use the || operator.
- This finds numbers where one condition is true.
Find divisors of a number.
- Set your number to 12.
- Loop from 1 up to your number.
- Use the % operator to find divisors.
Source: https://dev.to/raja_b_0c9d242e2c26cf063b/coding-program-js-2eod