Updated code

cleaned some useless thingies like notes, calculations, fixed indents