adding sample code for examples