Refined code to pick up first green pom and added code to pick up second green pom