trying to implement break statement