I know in the question's body, we can use `code` to specify inline
code like this.
But can we specify
code in the title of the question? And if not, why?
No, Markdown isn't run on the title whatsoever. Any special characters get converted to their entities. There's really no need to specify code in the title. If you're using too much code in the title, perhaps you should consider a better title. Normally we'd only see someFunction() or Some_Random_Class listed in the title, which is perfectly readable for the short amount of text present for that line. Inline code in posts is meant to make the code stand out more than anything.
In the body:
It's pretty hard to see those specific functions and classes in that huge block of text above without reading through it. Also, small code snippets such as
i + 3 == true would be difficult to spot or even comprehend. The inline code makes it stand out in that you see the formatted box and realize you're starting a piece of code, and that this block of text should be taken as a whole rather than as part of the sentence around it.
In the title:
The text is a lot bigger and limited in size, making it easy to find functions or classes it might be about.