3 ms·
import random platform = random.SystemRandom().choice(["Astro", "Blogger", "Hugo", "WordPress", "Ghost"]) print(platform)
by cpach 2y ago
import random
platform = random.SystemRandom().choice(["Astro", "Blogger", "Hugo", "WordPress", "Ghost"])
print(platform)
- maxbond 2y agoStylistic note, you can use `random.choice()`. If you aren't generating an encryption key, you probably don't need `SystemRandom`.
- cpach 2y agoTrue. It’s an idée fixe of mine. Doesn’t really cost anything extra though.
- tnvmadhav 2y agozsh: command not found: import /s
- cpach 2y agoTry this one: echo -e "Astro\nBlogger\nHugo\nWordPress\nGhost" | shuf | head -n 1