Python – Basic Recursion

url = 'www.website.com/page/'
count = 10

paging = range(count)
for x in paging:
    page = url + str(x+1)
    print(page)


Result :

www.website.com/page/1
www.website.com/page/2
www.website.com/page/3
www.website.com/page/4
www.website.com/page/5
www.website.com/page/6
www.website.com/page/7
www.website.com/page/8
www.website.com/page/9
www.website.com/page/10

Leave a Reply

Your email address will not be published. Required fields are marked *