Sharedlatex-tests / pytest2.texOpen in CoCalc
Author: Harald Schilly
1
\documentclass{article}
2
3
4
\usepackage{hyperref}
5
\usepackage[T1]{fontenc}
6
7
\usepackage{pythontex}
8
9
\title{Title of Document}
10
\author{Name of Author}
11
12
\begin{document}
13
\section{Python}
14
15
\begin{pycode}
16
import math
17
print(r'2 * Pi = {}'.format(2*math.pi))
18
\end{pycode}
19
20
The result of ... is \py{2+5}.
21
22
\end{document}
23
24