\documentclass[a4paper]{article}
\input{head}
\begin{document}
%-------------------------------
% TITLE SECTION
%-------------------------------
\fancyhead[C]{}
\hrule \medskip % Upper rule
\begin{minipage}{0.295\textwidth}
\raggedright
\footnotesize
YOURNAME \hfill\\
YOURSTUDENTID\hfill\\
YOURMAIL
\end{minipage}
\begin{minipage}{0.4\textwidth}
\centering
\large
Homework Assignment 1\\
\normalsize
Machine Learning 1, 17/18\\
\end{minipage}
\begin{minipage}{0.295\textwidth}
\raggedleft
\today\hfill\\
\end{minipage}
\medskip\hrule
\bigskip
%-------------------------------
% CONTENTS
%-------------------------------
\section{First Exercise}
\blindtext
\subsection{First Subtask}
Some equations
\begin{align*}
y &= \sum\limits_{i,k} m_i \cdot f^k \\
x &=
\underset{11}{\underbrace{3 + 8}} + 5 + 7
\end{align*}
\subsection{Second Subtask}
\blindtext
\bigskip
%------------------------------------------------
\section{Second Exercise}
\blindtext
\subsection{First Subtask}
\bigskip
%------------------------------------------------
\end{document}