modified to print