import urllib import json line = 10 row = 500 for i in range(0, row): fake_text = '' url = urllib.urlopen('http://more.handlino.com/sentences.json?n=%s' % line) result = url.read() sentences_lists = json.loads(result) fake_text = ''.join(sentences_lists['sentences']) print fake_text print len(fake_text)
API :
http://more.handlino.com/api
沒有留言:
張貼留言