Suggests using builtin functions for median, sample, shuffle, split_lines and zip

This commit is contained in:
Pablo Baeyens
2020-01-04 14:00:20 +01:00
parent 2ba974cd2d
commit ed8394afc8
5 changed files with 10 additions and 0 deletions

View File

@ -7,6 +7,8 @@ Returns a random element from a list.
Use `random.randint()` to generate a random number that corresponds to an index in the list, return the element at that index.
[`random.sample`](https://docs.python.org/3/library/random.html#random.sample) provides similar functionality to this snippet.
```py
from random import randint