-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.tex
More file actions
153 lines (129 loc) · 4.1 KB
/
main.tex
File metadata and controls
153 lines (129 loc) · 4.1 KB
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
% --------------------------------------------------
% PREAMBLE -----------------------------------------
% --------------------------------------------------
\documentclass{article}
% DOCUMENT
\setlength{\parskip}{1.3ex plus 0.2ex minus 0.2ex}
\setlength{\columnsep}{0.9cm}
\usepackage[landscape,twocolumn]{geometry} % Page layout
\geometry{
paper=a4paper,
tmargin=1.65cm,
bmargin=1.65cm,
lmargin=0.9cm,
rmargin=0.9cm,
headheight = 0pt,
headsep = 30pt,
footskip = 30pt
}
\usepackage{fancyhdr} % Headers
% * 'fancyhead' and 'fancyfoot' writes to all fielsds
% * 'leftmark' and 'rightmark' have the info of two top-level sections
% * 'sectionmark', I don't know
\pagestyle{fancy}
\renewcommand{\sectionmark}[1]{\markboth{#1}{}}
\fancyhead{}
\fancyfoot{}
\rhead{\nouppercase{\leftmark}}
\cfoot{\thepage / \pageref*{LastPage}}
% ENCODING
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[spanish]{babel}
% MATH
\usepackage{amsmath} % Has everything
\usepackage{amssymb} % Math symbols
\usepackage{dsfont} % Domain font
\usepackage{amsthm} % Theorems
\newtheorem*{teorema}{Teorema}
\newtheorem*{proposicion}{Proposición}
\newtheorem*{lema}{Lema}
\newtheorem*{corolario}{Corolario}
% ALGORITHMS
\usepackage{algorithm} % Algorithm floats
\floatname{algorithm}{Algoritmo}
\usepackage{algorithmicx} % Macro definitions for algorithm typesetting
\usepackage{algpseudocode} % Pseudocode package built with algorithmicx
\algrenewcommand\algorithmicrequire{\textbf{Requiere}}
\algrenewcommand\algorithmicensure{\textbf{Asegura}}
% MISC
\usepackage{import} % Recursive Import
\usepackage{graphicx} % Images
\usepackage{lastpage} % Reference to last page
\usepackage{enumitem} % List control
\PassOptionsToPackage{usenames,dvipsnames}{xcolor}
\usepackage[draft]{todonotes} % Todo's
\newcommand\myshade{75}
% violet, YellowOrange, Aquamarine, OliveGreen, RubineRed
\usepackage{hyperref} % Hyperlinks
\hypersetup{
colorlinks = true,
urlcolor = OliveGreen!\myshade!black,
linkcolor = red,
citecolor = red
}
\usepackage{lipsum} % Lorem Ipsum
\usepackage{tabularx} % Table control
\usepackage{listings} % Source Code
\lstset{
language=C++,
basicstyle=\ttfamily,
basewidth = {.45em,0.45em},
backgroundcolor=\color[rgb]{0.9,0.9,0.9},
keywordstyle=\color[rgb]{0,0,0.6},
morekeywords={vector,pair,stack,tuple,queue,map,unordered_map,set,list},
xleftmargin=4pt,
xrightmargin=4pt,
frame=tlbr,
framesep=4pt,
framerule=0pt,
escapechar=\#% char to escape out of listings and back to LaTeX
}
\newcommand{\cppfile}[1]{
\lstinputlisting[language=C++]{#1}
}
% FONTS
\renewcommand*\rmdefault{ptm} % Times
\newcommand*{\comment}[1]{\hfill\makebox[3.0cm][r]{#1}}%
\newcommand*{\oh}[1]{\comment{$O(#1)$}}%
\newcommand*{\amortizedoh}[1]{\comment{$amortized \,\, O(#1)$}}%
\newcommand*{\amortizedohk}[1]{\comment{$amortized \,\, O(#1) + K$}}%
\newcommand*{\cmod}{\, \% \,}%
\newcommand*{\cppalgo}[1]{\comment{$amortized \,\, O(#1)$}}%
\newcommand*{\impls}[1]{\begin{flushright} \vspace{-24pt} \texttt{#1} \end{flushright}}
% ---------------------------------------------------
% MAIN ----------------------------------------------
% ---------------------------------------------------
\begin{document}
\tableofcontents
\pagebreak
\section{Programación}
\input{programming/c++/c++.tex}
\pagebreak
\input{programming/bits/bits.tex}
\pagebreak
\section{Algoritmos}
\input{algorithms/algorithms.tex}
\pagebreak
\section{Estructuras de Datos}
\input{structures/structures.tex}
\pagebreak
\section{Strings}
\input{strings/strings.tex}
\pagebreak
\section{Geometria}
\input{geometry/geometry.tex}
\pagebreak
\section{Matemática}
\input{math/algebra/algebra.tex}
\pagebreak
\input{math/modulo/modulo.tex}
\pagebreak
\input{math/game_theory/game_theory.tex}
\pagebreak
%\input{math/primes/primes.tex}
%\pagebreak
\section{Miscelaneas}
\import{general/}{general.tex}
\pagebreak
\end{document}