added intermediate print