The Markdown editing help page currently leads with this code example:

printf("%d\n", 42);  /* What was the
 question again? */

(This quote excludes the four highlighted spaces at the start of each line.)

Obviously, this example comes from the winning answer to a contest, by Frédéric Hamidi. But it is not quite the same. The answer says:

printf("%d\n", 42);  /* What was the
                        question again? */

This specific spacing was added in an edit (by the answer’s original author) with this description:

Ah, silly me, this is supposed to teach how whitespace works in code blocks. Better keep demonstrating fixed-width alignment, then.

It also reflects the previous example (given in the contest question):

printf("goodbye world!");  /* his suicide note
                              was in C */

The Markdown help page should preserve the spaces used in the answer.

  • 5
    It comes from a bug. The correct spacing is in the source code but our Markdown parser is stripping it out for whatever reason.
    – animuson StaffMod
    Aug 17, 2022 at 15:04


You must log in to answer this question.

Browse other questions tagged .