updated to with statement