PSA: Escaping (Aka: How to make characters appear instead of work)


I’ve come across a few cases where people didn’t know about Escaping or why it didn’t work exactly as they intended it to. Since in most cases I told these people in a PM, today I’ll just do it in this thread for everyone who doesn’t know this yet.

Escaping is the difference between Italics and *some Italics Syntax Demonstration*.

This formatting is done using control structures like BBCode or Markdown, I’ll use latter here.

One of these control structures is the backslash: “\” Its purpose is, if I think about it, to switch the role of a character from control character to output character or the other way around, depending on the situation. In the programming language C for example, “n” is a perfectly normal character to be outputted by the printf function - until you write \n and it turns into a newline.

So if you want to write *Italics* but don’t want it to show up in italics, you’d escape the control character like this:

\*I'm an example!\*

*I’m an example!*

But wait, how do you escape the Backslash? By using it on itself:



The more you double it, the deeper it goes:



More Examples

# can be used in Markdown to start a heading. \# makes it visible:



¯\_(ツ)_/¯ contains \ as well as _ which can be used for italics and bold text like *. So without intentional Escaping, it looks like this:



The backslash stops _ from controlling italics. One more backslash:



The backslash is escaped by the other one, the _ is now the italics control character. The ending counterpart is on the right side. The solution is a triple backslash:



Seems fine.

I’m not completely sure about the rules and it probably won’t work everywhere the same way so I’m not sure if I should play it safe and use


which doesn’t appear to make a difference here. Just like

\*I'm an example!*

for the first example saving a character instead.

It does help when your emoticon introduces another _ though:

¯\\\_(ツ)_/¯ works fine :slight_smile:

¯\_(ツ)_/¯ works fine :slight_smile:

¯\\\_(ツ)\_/¯ works fine :slight_smile:

¯\_(ツ)_/¯ works fine :slight_smile:

In conclusion: Check the preview.

First World Problem

I’d like this but there’s no like button


Look what I found after a single Google search for “show markdown character”.

And the answer here gets to the point instead of having me read through the history of markdown.


And here I thought I was able to start at least one single damn thread without someone telling me I wasted their time or making me start elaborating on my words…

Looks like you’re not my target audience as you luckily know what you need to look for and google it instead of being surprised your post looks weird.

Your linked post barely explains it, just listing one simple example so it’s also not what this thread was for, as you can read in the first paragraph of the OP.