Basic functions implemented

At least it counts sth.