Problem scenario
You do not want to install new Python modules. How do you use Python to print out the latest price of Bitcoin?
Solution
Run this program:
import requests
resp = requests.get("https://api.coindesk.com/v1/bpi/currentprice/USD.json")
print(resp.json()['bpi'])
Here is a modified version of the program:
import requests
resp = requests.get("https://api.coindesk.com/v1/bpi/currentprice/USD.json")
print(resp.json()['bpi']['USD']['rate'])
If you want to receive free cryptocurrency by just learning more, try Coinbase; it is ideal for Americans. For Europeans, the platform/company Iconomi.com can allow you to buy crypto or learn more.