Skip to content
Better HN
Top
Best
Ask
Show
New
Jobs
Search
⌘K
0 points
jfkebwjsbx
6y ago
0 comments
Save
Share
Tip: you can use four leading spaces to write code.
Like this
0 comments
5 comments · 1 top-level
top
newest
oldest
steveklabnik
6y ago
· 4 in thread
You only need two!
like this
DougGwyn
6y ago
I tried, but two spaces yielded what you saw.
dang
6y ago
Huh, it also needed an extra line break before the first line of code. I didn't realize that! I've fixed it now.
2 more replies
sgt
6y ago
I did not know that, after spending years on HN.
while(1) fork();
steveklabnik
6y ago
https://news.ycombinator.com/formatdoc
j
/
k
navigate · click thread line to collapse