# 示例

自动重发作品：

```python
import turingAPI
userCookie = input('请输入用户cookie：')
user = turingAPI.icodeUser(userCookie)
url = None
workIds = []
while url != 'done':
    url = input('输入要自动重发的作品网址（输入done结束）：')
    if url != 'done':
      workData = user.getWorkDetail(user.getWorkId(url), True)
      workListData = [user.getWorkId(url), 
            workData['codeLanguage'], 
            workData['code'], 
            workData['title'],
            workData['imgUrl'],
            workData['description']]
      workIds.append(workListData)
while True:
    for i in workIds:
        if i[1] == 'scratch':
            user.reSubmitScratch(i[0], i[2], 1, i[3], i[5], i[4])
        else:
            user.reSubmitPython(i[0], i[2], 1, 0, i[3], i[5], i[4])
```
