I am in Java Programming at my school, and we are using Karel. We are using booleans right now, which i understand. However, I am curious as to how to turn the robot off when it reaches x,x coordinates. I tried asking the teacher, but he said it is too much of a hassle to try and explain it.

I may or may not try using this, but I am using recursion to loop my methods (haven't really learned loops yet, he just mentioned loops yesterday) and right now I am having the robot turn off if it detects a beeper, which does not look too pretty as it is not really following the assignment instructions to have a beeper at the end.

Short summary: I would like to know if someone can explain how to make Karel turn off when it reaches x,x coordinates.