0
Password Generator
https://code.sololearn.com/c6WC3Bys9bzG/?ref=app Anyone can explain to me how does this works? I've recently finished learning python but now I feel like I don't know anything lol
2 Answers
+ 2
Pythonâs random module has a function called sample. Sample takes two inputs, in this case, a string of characters and the amount of times you want it to get a random character from that string. The "".join() takes that list and joins each item together into one string with no delimeter so that it becomes one âwordâ, and there you have a password made randomly from the character string âxâ!
0
Now I get it. Thank you for your help :)