I am using a for loop and it requires me to print something. Each time it prints I dont want the output to be on a seperate line. How do I do this?
def getGuessedWord(secretWord, lettersGuessed):
for i in secretWord:
if (i in lettersGuessed):
print(i)
else:
print ("_")
This code is for a hangman game Thanks in advance