We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ecad21a commit 4960ff8Copy full SHA for 4960ff8
web-scraping/wikipedia-extractor/wikipedia_extractor.py
@@ -36,3 +36,11 @@
36
print("References:", references, "\n")
37
print("Summary:", summary, "\n")
38
39
+# changing language
40
+# for a list of available languages,
41
+# check http://meta.wikimedia.org/wiki/List_of_Wikipedias link.
42
+language = "es"
43
+wikipedia.set_lang(language)
44
+# get a page and print the summary in the new language
45
+print(f"Summary of web scraping in {language}:", wikipedia.page("Web Scraping").summary)
46
+
0 commit comments