Hmmm. I guess this probably works well, but this form of goto is somewhat magical, I am not sure it should be advised to someone probably not understanding the details and, more broadly, for such a simple task, where a while loop or a simple recursive call would do as well.