I have a README.md markdown file that I use to describe a project that is hosted on GitHub. Within this file I have several headlines and sub-headlines, each starting with one or more hashes, as usual in markdown.
Now I want to set the text of one headline to C#, but GitHub does not respect the hash a part of the text, but interprets it as an (optional) closing hash for the headline.
Even if I escape the hash by prefixing it with a backslash, it does not work. So if I type
## C#
I get:
C
If I use
## C\#
I get:
C\
How do I write this head-line in a correct way?
Method 1
You could use a true sharp sign,
♯, instead of the hash sign,#. From the Wikipedia page on C♯:Here
## C♯producesC♯
Method 2
Alternatively, (at least on this site) just put a space after the last
#, for example## C\#producesC#
Note that Pandoc seems to handle
# C\#correctly (try it).