- Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path04.py
More file actions
Latest commit
18 lines (15 loc) · 410 Bytes
/
Copy path04.py
File metadata and controls
18 lines (15 loc) · 410 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
importrequests
defgetNext(arg):
url="http://www.pythonchallenge.com/pc/def/linkedlist.php"
params="nothing={}".format(arg)
res=requests.get(url, params)
cont=res.text
print(cont)
ary=cont.split(' ')
next_arg=ary[-1]
ifnext_arg.isdigit():
print(next_arg)
getNext(next_arg)
else:
print("result is: {}".format(next_arg))
getNext(12345)