This content originally appeared on DEV Community and was authored by Phoenix
Hi, friends!
You Can use the Wikipedia API for this work;
Look this Code:
import requests as rq
Query = "iran"#What Do You Want To Search In wikipedia
Lang = "en"#Your Language
Url = f"https://{Lang}.wikipedia.org/api/rest_v1/page/summary/{Query}"
Result = rq.get(Url).json()['extract']
print(str(Result))
Run and See The Result.
Do not forget to like!
Bye until the next postđź‘‹
This content originally appeared on DEV Community and was authored by Phoenix
Phoenix | Sciencx (2021-12-18T20:29:28+00:00) How to get a summary of the a page in Wikipedia?🤔. Retrieved from https://www.scien.cx/2021/12/18/how-to-get-a-summary-of-the-a-page-in-wikipedia%f0%9f%a4%94/
Please log in to upload a file.
There are no updates yet.
Click the Upload button above to add an update.