code for proba to leave and next location