clean up sample codes