can somebody pls tell me how to exit an array.

say maybe you're looping through an array for a certain condition and if the condition is found it returns true and exists the array.

this is something that cannot be done with in_array()