# Getting started

## Inline math

Inline math can be written in two ways. They can be enclosed
within `$`

and `$`

, or `\(`

and `\)`

. For example, typing
`$e^{i \pi} + 1 = 0$`

or `\(e^{i \pi} + 1 = 0\)`

in the code
pane would produce the following output: $e^{i \pi} + 1 = 0$.

## Displayed math

Displayed math appears on its own line. To render displayed
math, they can be enclosed within `$$`

and `$$`

, or `\[`

and
`\]`

. For example, typing `$$e^{i \pi} + 1 = 0$$`

or
`\[e^{i \pi} + 1 = 0\]`

in the code pane would produce the
following output: $$e^{i \pi} + 1 = 0.$$ Apart from this, many
LaTeX environments such as `equation`

, `align`

, etc. are also
supported. The list of supported environments can be found at
MathJax documentation on supported environments

## Text

Mathematics and text can be mixed freely while posting a math snippet. Markdown is a supported format for writing text. As you can see, this tutorial itself is another post, so you can compare the code in the left hand pane with the output in the right hand pane as you read this tutorial. A new paragraph begins by placing a blank line in the code.

This is a new paragraph. Check the code pane on the left hand side to ensure that there indeed is a blank line between this paragraph and the previous one.

Code blocks must be indented by four spaces.

```
#include <stdio.h>
int main(int argc, char **argv)
{
printf("hello, world\n");
}
```

Ordered lists can be written by numbering each line.

- Apple
- Mango
- Banana

Unordered lists can be written by using asterisks, pluses, or hyphens as bullets for each line.

- Apple
- Mango
- Banana

Enclose text within a pair of asterisks to *emphasize* it.
Enclose text within a pair of double-asterisks to **emphasize it
strongly**. You may use underscores instead of asterisks to add
emphasis too.

Various other features are supported in Markdown such as inline code, blockquotes, horizontal rules, etc. For a complete tutorial on Markdown, see the Markdown syntax documentation.

## LaTeX help

This website uses MathJax to render math on the browser, so the set of LaTeX commands that would work depends on the set of LaTeX commands supported by MathJax. For a list of LaTeX commands supported by MathJax, see their documentation on LaTeX support. To learn how to use LaTeX, see http://en.wikibooks.org/wiki/LaTeX/Mathematics.

## Markdown help

This website supports Markdown. To learn how to write text in Markdown, see the Markdown syntax documentation.