21
說明:
|
313
|
這個顏色代表刪除的 | 這個顏色代表增加的 |
行號 1: | 行號 1: |
Python 是什麼? | import json from urllib.request import urlopen url = "https://gdata.youtube.com/feeds/api/standardfeeds/top_rated?alt=json" response = urlopen(url) contents = response.read() text = contents.decode('utf8') data = json.loads(text) for video in data['feed']['entry'][0:6]: print(video['tittle']['$t']) |
import json from urllib.request import urlopen url = "https://gdata.youtube.com/feeds/api/standardfeeds/top_rated?alt=json" response = urlopen(url) contents = response.read() text = contents.decode('utf8') data = json.loads(text) for video in data['feed']['entry'][0:6]:
- print(video['tittle']['$t'])