2
0
Fork 0
mirror of https://github.com/MartinThoma/LaTeX-examples.git synced 2025-04-26 06:48:04 +02:00

Added source files (Programmieren Tutorium)

This commit is contained in:
Martin Thoma 2013-11-05 19:39:03 +01:00
parent 1be8f17cc0
commit ad81fa802b
244 changed files with 8252 additions and 0 deletions

View file

@ -0,0 +1,25 @@
\section{Stilfragen}
\subsection{So nicht}
\begin{frame}{So nicht}
\inputminted[linenos, numbersep=5pt, tabsize=4, frame=lines, label=pi.c, fontsize=\tiny]{c}{pi.c}
Quelle: \href{http://www.cise.ufl.edu/~manuel/obfuscate/obfuscate.html}{Obfuscated C Code}
\end{frame}
\subsection{Aber so}
\begin{frame}{Aber so}
\inputminted[linenos, numbersep=5pt, tabsize=4, frame=lines, label=pi-good.c]{c}{pi-good.c}
Nur halt in Java (Ich will keine C Abgaben sehen! In dem
Modul "`Programmieren"' wird ausschließlich Java behandelt.)
\end{frame}
\subsection{Hinweise zu gutem Programmierstil}
\begin{frame}{Hinweise zu gutem Programmierstil}
\begin{itemize}
\item Sinnvolle Modellierung ("`ist ein"' bzw. "`hat"')
\item Aussagekräftige Namen (Klassen, Methoden, Variablen)
\item JavaDoc
\item Hilfreiche Kommentare (für die Abschlussaufgabe: lieber zu viele)
\item Kurze Funktionseinheiten
\end{itemize}
\end{frame}

View file

@ -0,0 +1,10 @@
#!/usr/bin/env python
import datetime
tmpDay = datetime.date.today() # von
lastday = datetime.date(2014,2,10) # bis (Vorlesungsende?)
while tmpDay < lastday:
if tmpDay.weekday() == 0:
print tmpDay.strftime('%d.%m.%Y')
tmpDay += datetime.timedelta(days=1)