removes misplaced delete[]
properly fprintfs values
pauses program on sleep command