![]() ![]() To open any website, we need to import a module called webbrowser. – Defining Task 2: To open YouTube site in a web-browser If Wikipedia is found in the user’s search query, then two sentences from the summary of the Wikipedia page will be converted to speech with the help of speak function. In the above code, we have used an if statement to check whether Wikipedia is in the search query of the user or not. Speak ( "According to Wikipedia" ) print (results ) lower ( ) #Converting user query into lower case # Logic for executing tasks based on query if 'wikipedia' in query : #if wikipedia found in the query then this block will be executed ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |