From a5941dfdd7777e39a25c8a47002f45c11340f181 Mon Sep 17 00:00:00 2001 From: Flora Jiang Date: Fri, 28 Jun 2019 00:46:29 -0700 Subject: [PATCH 1/2] Fix a api parameter usage in code --- ...47\231\276\345\272\246\345\234\260\345\233\276API.ipynb" | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git "a/\347\254\254\344\272\214\347\211\210/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API.ipynb" "b/\347\254\254\344\272\214\347\211\210/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API.ipynb" index 2b804eb..5dbcc44 100644 --- "a/\347\254\254\344\272\214\347\211\210/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API.ipynb" +++ "b/\347\254\254\344\272\214\347\211\210/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API.ipynb" @@ -803,7 +803,7 @@ " decodejson = getjson(eachprovince)\n", " for eachcity in decodejson['results']:\n", " city = eachcity['name']\n", - " num = eachcity['num']\n", + " num = getjson(city)['total']\n", " print (city, num)\n", " output = '\\t'.join([city, str(num)]) + '\\r\\n'\n", " with open('cities.txt', \"a+\", encoding='utf-8') as f:\n", @@ -846,7 +846,7 @@ "six_cities_list = ['北京市','上海市','重庆市','天津市','香港特别行政区','澳门特别行政区',]\n", "for eachprovince in decodejson['results']:\n", " city = eachprovince['name']\n", - " num = eachprovince['num']\n", + " num = getjson(city)['total']\n", " if city in six_cities_list:\n", " output = '\\t'.join([city, str(num)]) + '\\r\\n'\n", " with open('cities.txt', \"a+\", encoding='utf-8') as f:\n", @@ -1308,7 +1308,7 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.6.5" + "version": "3.7.0" }, "toc": { "base_numbering": 1, From fc3b835b89debe6a855b5073163dd696ec35d126 Mon Sep 17 00:00:00 2001 From: Flora Jiang Date: Fri, 28 Jun 2019 01:30:38 -0700 Subject: [PATCH 2/2] =?UTF-8?q?Update=20=E7=AC=AC=E4=BA=8C=E7=89=88/Cha=20?= =?UTF-8?q?16=20-=E7=88=AC=E8=99=AB=E5=AE=9E=E6=88=98=E4=B8=89=EF=BC=9A?= =?UTF-8?q?=E7=99=BE=E5=BA=A6=E5=9C=B0=E5=9B=BEAPI/Cha=2016=20-=E7=88=AC?= =?UTF-8?q?=E8=99=AB=E5=AE=9E=E6=88=98=E4=B8=89=EF=BC=9A=E7=99=BE=E5=BA=A6?= =?UTF-8?q?=E5=9C=B0=E5=9B=BEAPI.ipynb?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: LitoMore --- ...32\347\231\276\345\272\246\345\234\260\345\233\276API.ipynb" | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git "a/\347\254\254\344\272\214\347\211\210/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API.ipynb" "b/\347\254\254\344\272\214\347\211\210/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API.ipynb" index 5dbcc44..fb3e8cf 100644 --- "a/\347\254\254\344\272\214\347\211\210/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API.ipynb" +++ "b/\347\254\254\344\272\214\347\211\210/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API/Cha 16 -\347\210\254\350\231\253\345\256\236\346\210\230\344\270\211\357\274\232\347\231\276\345\272\246\345\234\260\345\233\276API.ipynb" @@ -1308,7 +1308,7 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.7.0" + "version": "3.6.5" }, "toc": { "base_numbering": 1,