Last active
July 15, 2019 18:33
-
-
Save lavaboom/8a9dfd0fc2b51a0c6be86173feeb3317 to your computer and use it in GitHub Desktop.
[SlotSimUtils] A collection of utils function used in slot sim and probabilities calculation #python #slot #casino
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def get_random_option_from_weight(options, weights): | |
| ''' | |
| python 3.6 and later | |
| ''' | |
| import random | |
| return random.choices(options, weights)[0] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment