Created
March 21, 2019 17:21
-
-
Save glitchedmob/a44c0fae5b7113c16a1a66fb97732047 to your computer and use it in GitHub Desktop.
This file contains 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 list_get(arr, index, default=None): | |
return arr[index] if index < len(arr) else default |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment