Skip to content

Instantly share code, notes, and snippets.

@fatosmorina
Created August 1, 2021 14:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fatosmorina/50508fa5be6cb38d2d1ba5784089a245 to your computer and use it in GitHub Desktop.
Save fatosmorina/50508fa5be6cb38d2d1ba5784089a245 to your computer and use it in GitHub Desktop.
import random
my_list = [1, 2, 3, 4, 5]
random.shuffle(my_list)
print(my_list)
# A possible result: [5, 3, 4, 1, 2]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment