On 4/18/2023 7:18 PM, Kevin M. Wilson via Python-list wrote:
Greetings... Kevin here:I need help, as you have guessed!I have this line: The 
Print Statement... Why complain about a 'comma', or a ')'???def play_game():
     number = random.randint(1, LIMIT)
     print (f'"I am thinking of a number between 1 to {LIMIT}\n")Or is this a 
setting in the IDE, I need to reassign?

I'm not sure what error you are talking about, but the f-string isn't closed (and doesn't appear to need the double quotes, either, though that is not an error). So -

print (f'I am thinking of a number between 1 to {LIMIT}')

(print() will add its own newline at the end so you don't need the \n unless you actually want another newline).

Next time, please include the actual error message and make sure you include line breaks so things don't run together.


Regards, Perplexed
"When you pass through the waters, I will be with you: and when you pass through the 
rivers, they will not sweep over you. When you walk through the fire, you will not be 
burned: the flames will not set you ablaze."
Isaiah 43:2

|  | Virus-free.www.avg.com |


--
https://mail.python.org/mailman/listinfo/python-list

Reply via email to