tweaked code blocks