-1
import webbrowser
number = input('Enter text ')
webbrowser.open("https://www.bing.com/search?q=",number)
exit = input('press any key to exit')

Basically I need to search for an input that the user says, but when the user presses enter it only searches for www.bing.com/search?q=

Henry Ecker
  • 34,399
  • 18
  • 41
  • 57
BilliesBob
  • 11
  • 2
  • when the user types something, it should search "www.bing.com/search?q= " and then add at the end the thing he wrote. also dont worry about spaces i just need help with this i will fix it alone – BilliesBob Nov 01 '20 at 20:28
  • 1
    Welcome to stackoverflow. Please read [ask] before asking your next question. Your title is poorly chosen; it doesn't say anything about your question. Also [edit] your question instead of adding comments for clarification; comments may or may not be shown initially and in in any order. Don't ask for people to not downvote you, write good questions instead. People don't downvote you for beginner questions, they downvote you for sloppy questions, lack of effort, dumping homework questions, and so on. – Robert Nov 01 '20 at 20:43

1 Answers1

1

Try doing this:

webbrowser.open(f"https://www.bing.com/search?q={number}")

Using f-strings, it should work!

PythonPikachu8
  • 359
  • 2
  • 11