0

Possible Duplicates:
Valid use of goto for error management in C?
Examples of good gotos in C or C++
GOTO still considered harmful?
To Use GOTO or Not?

The goto statement seems very risky to use. When would it be a good scenario to use a goto statement instead of nesting control statements? Is it even a preferred way of controlling a program flow?

Community
  • 1
  • 1
Babiker
  • 17,652
  • 27
  • 74
  • 122

1 Answers1

1

GoTo is good just for error handling in VB6, when you program in assembler or for a Pic. In high level programming it's considered a bad practice because "breaks" the program control flow and also makes the code harder to read.

Broken_Window
  • 1,940
  • 3
  • 20
  • 41