Computer Science, asked by karishmachawla368, 2 months ago

What types of goto usage should be avoided and why? Justify your answer by

considering a suitable example.

Answers

Answered by 12ishika19
0

Answer:

IDL's GOTO statement is a control statement that is used to jump to a specific point in the code. It is similar to "goto" in C++ and many other languages. "How convenient!" you might say. "A quick, easy way to jump to a desired section code if certain conditions are met."

Not so fast.

Most programmers will tell you that the GOTO statement should be avoided. In fact, IDL's own documentation advises against it. Actually, it doesn't advise against it; it outright states that using it is bad programming:

"The GOTO statement is generally considered to be a poor programming practice that leads to unwieldy programs. Its use should be avoided."

Similar questions