Updated, almost done
Added in the print writer for output file