Answers for "python wikipedia page"

2

how to make wikipedia using python

please subscribe my channel - https://bit.ly/2Me2CfB

import wikipedia

word = str(input("ENTER THE WORD : "))

print("WHAT DO YOU WANT TO GET OF THE WORD YOU ENTERED : ")
print(":\t1\tSummary")
print(":\t2\tExamples")
print(":\t3\tEssay")
choice = int(input("ENTER YOUR CHOICE : "))
if choice == 1:
    print(word, " :")
    wki1 = wikipedia.summary(word)
    print(wki1)
elif choice == 2:
    print(word, " :")
    wki2 = wikipedia.search(word)
    print(wki2)
elif choice == 3:
    print(word, " :")
    wki3 = wikipedia.page(word)
    print(wki3)
else:
    print("INVALID CHOICE!!")
Posted by: Guest on July-10-2021
3

python wikipedia

import wikipediaapi

wiki = wikipediaapi.Wikipedia("en")
page = wiki.page("Python (programming language)")

print(page.summary)
# Python is an interpreted, high-level and general-purpose programming language. Python's design philosophy emphasizes code readability with its notable use of significant indentation. Its
# language constructs and object-oriented approach aim to help programmers write clear, logical code for small and large-scale projects.
# Python is dynamically-typed and garbage-collected. It supports multiple programming paradigms, including structured (particularly, procedural), object-oriented and functional programming.
# Python is often described as a "batteries included" language due to its comprehensive standard library.Guido van Rossum began working on Python in the late 1980\'s,
# as a successor to the ABC programming language, and first released it in 1991 as Python 0.9.1. Python 2.0 was released in 2000 and introduced new features, such as list comprehensions
# and a garbage collection system using reference counting and was discontinued with version 2.7.18 in 2020. Python 3.0 was released in 2008 and was a major revision of the
# language that is not completely backward-compatible and much Python 2 code does not run unmodified on Python 3.
# Python consistently ranks as one of the most popular programming languages.
Posted by: Guest on March-18-2021

Python Answers by Framework

Browse Popular Code Answers by Language