What lunatic taught you to use goto
like that? Or at all, for that matter? If your professor is teaching to write code like that - hell, if you professor even mentioned goto
in the first place - you should walk away from that course.
Here's a piece of advice: forget that the keyword goto
exists. You should never, ever use it for ordinary flow control. It is far too difficult to debug code that uses it. While goto
does have its place in C programming, someone just learning the language shouldn't touch it.