Cybersecurity

Strong Passwords

A weak password is the #1 way accounts get broken into — not clever hacking, just guessing. "password123" or your pet's name can be cracked by a computer trying millions of guesses a second.

A strong password is long (12+ characters beats clever-but-short), uses a mix of upper/lowercase letters, numbers, and symbols, and isn't a real word or anything personal (birthday, name, school). A password manager or a memorable random phrase ("PurpleTiger$Jumps47") beats a clever short word every time.

Your turn

Write a function checkPassword(pw) that returns true only if the password is at least 12 characters long AND contains at least one number. Test it with a few passwords using console.log.

Output shows up here when you Run.
Ask JARVIS for a hint