I'm trying to run this Python program with Visual Studio Code:
# This Python program must be run with # Python 3 as it won't work with 2.7. # ends the output with a <space> print("Welcome to" , end = ' ') print("GeeksforGeeks", end = ' ')
But while building I get following output and error messages in console:
$ python /home/mrrobot/Documents/Python/loop_while.py File "/home/mrrobot/Documents/Python/loop_while.py", line 5 print("Welcome to" , end = ' ') ^ SyntaxError: invalid syntax
What could be the problem here? How can I fix it?