Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env python
- import requests
- main22 = "https://moodlearn.ariel.ac.il/course/view.php?lang=en&id="
- def checksite(a):
- r = requests.get(main22 + str(a))
- if "Guests cannot" not in r.text and "More information about this error" not in r.text and "unavailable to students" not in r.text:
- print(a)
- with open("Opencourses.txt","a") as myfile:
- myfile.write(str(a) + "\n")
- for i in range(50000,100000):
- if i%100 == 0:
- print("passed "+str(i));
- checksite(i)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement