课程: Level Up: Python

今天就学习课程吧!

今天就开通帐号,24,700 门业界名师课程任您挑!

Generate a password

Generate a password

(playful music) - Security experts recommend using a different password for each of your online accounts. So this challenge will involve writing a Python function to generate new passwords, which is good programming practice for working with randomness. Now I have a hard time remembering passwords like this one. It's a mess of letters, numbers, and special characters. For my own passwords, I prefer to use a system called Diceware to generate easier to remember pass phrases. It involves using a list of over 7,000 different words. Each word is associated with a five digit number, where each of the digits in that number is between one through six. You roll dice to generate a sequence of five random numbers, which corresponds to one of those words. Repeat that process several more times and the sequence of random words the dice chooses is your new passphrase. As a human, it's a lot easier to remember a sequence of words…

内容