changed code snippet segment to look better