polished the example