remove unnecessary printlns, whitespace