added simplified code example