blob: e48693a45a6f7fe18dc794e2762606f5037aa8d3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
\documentclass{elteikthesis}[2023/04/10]
\usepackage[newfloat]{minted}
\begin{document}
\documentlang{english}
\chapter{Minted source code example}
\label{ch:chapter}
\begin{listing}[H]
\begin{minted}{cpp}
#include <stdio>
int main()
{
int c;
std::cout << "Hello World!" << std::endl;
std::cout << "Press any key to exit." << std::endl;
std::cin >> c;
return 0;
}
\end{minted}
\caption{Hello World in C++}
\end{listing}
\phantomsection
\addcontentsline{toc}{chapter}{\lstcodelabel}
\listoflistings
\end{document}
|