Slightly changed code to show parallel between if clause and else clause