Created
February 25, 2019 18:42
-
-
Save mkaz/369bb244adc6ede0ff5d4148006a42fe to your computer and use it in GitHub Desktop.
People currently in Space
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
#!/usr/bin/env python3 | |
""" How many people currently in space """ | |
import json, requests, sys | |
response = requests.get('http://api.open-notify.org/astros.json') | |
data = response.json() | |
print(data["number"]) | |
sys.exit(0) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment