In [1]:
import sys
print('hello world', flush=True)
for i in range(3):
    print(i, flush=True)
print('output to stderr', file=sys.stderr, flush=True)
print('some more stdout text', flush=True)


hello world
0
1
2
output to stderr
some more stdout text

Markdown Cell

$ e^{ \pm i\theta } = \cos \theta \pm i\sin \theta + \beta $

It really is!


In [2]:
this is a syntax error


  File "<ipython-input-2-6c5185427360>", line 1
    this is a syntax error
                   ^
SyntaxError: invalid syntax

In [3]:
from IPython.display import Image
Image('./jupyter.png')


Out[3]:

In [4]:
from IPython.display import Latex
Latex('''The mass-energy equivalence is described by the famous equation
 
$$E=mc^2$$
 
discovered in 1905 by Albert Einstein. 
In natural units ($c$ = 1), the formula expresses the identity
 
\\begin{equation}
E=m
\\end{equation}''')


Out[4]:
The mass-energy equivalence is described by the famous equation $$E=mc^2$$ discovered in 1905 by Albert Einstein. In natural units ($c$ = 1), the formula expresses the identity \begin{equation} E=m \end{equation}

In [ ]: