1

I want to print a single slash using print r in Python. For example:

print r"heythere\"

But this line gives an error. But if you put anything after that slash it will be printed, for example: print r"heythere\hey"

What I did wrong, how can I print slash? I don't want to use anything else, only working with print r" ".

Roim
  • 2,778
  • 2
  • 9
  • 23
CodeSpeedy
  • 601
  • 6
  • 10

0 Answers0