Hello, I'm sure there is a simple solution to this but I cannot seem to find the information I need in my textbook or online.

I'm creating a GUI with an entry box for the user to input their name.
I then use getText() to retrieve the name they entered and call it "player".
PROBLEM: What I want to do is incorporate the variable name "player" into the string in the text object (line 2).
How do I mix both strings AND variables in this particular part of the code?

player = enterName.getText()
greeting = Text(Point(300, 250), "Hello," player, "and good night")

Thanks in advance!

greeting = Text(Point(300, 250), "Hello," + player + "and good night")
print_str = "Hello," + player + "and good night"
greeting = Text(Point(300, 250), print_str)


I dont know how far will this help you , but there is a module called easygui which is really very very easy to use , your question can be done soo easily

from easygui import *
name =  enterbox (" Welcome user , please enter your name " , "My APP ")
msgbox("Hello" + str(name) + " \n Press ok to quit" )