Skip to content

Instantly share code, notes, and snippets.

@jgould22
Created July 26, 2017 18:05
Show Gist options
  • Save jgould22/a37969a507093318923e76978c434ecb to your computer and use it in GitHub Desktop.
Save jgould22/a37969a507093318923e76978c434ecb to your computer and use it in GitHub Desktop.
This reads from std in and stores the results in a list of lists using Python
import sys
list_of_lists = []
for line in sys.stdin:
new_list = [int(elem) for elem in line.split()]
list_of_lists.append(new_list)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment