Question: When using the following code, like shown, I keep getting an error of 'can only concenate str not list'. Any help? I am very grateful.

When using the following code, like shown, I keep getting an error of 'can only concenate str not list'. Any help? I am very grateful. Thank you!

import urllib.request import json link = "https://api.openweathermap.org/data/2.5/weather?zip=72714&appid=e7c3fb6e681c8f7bb59af33f1dc8bbca" print(link) f = urllib.request.urlopen(link) data = f.read() print(str(data, 'utf-8') weather = json.loads(data) print('/n') print (weather["name"]) print (weather["main"]["temp"])

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!