This is probably a really simple question but I can’t seem to get my head around it. I need to have a string that contains \" without it seeing it as an escape character. I tried using @ but it won’t work. The only other way I thought of doing this would be to use \u0022 but don’t want to unless I can help it.
Desired string – string s = "\"\""; // Obviously this doesn't work!
Desired console output – \"\"
Hope this makes sense.
Thanks!
Try
You have to escape your backslashes too.
Mike