What is label in c language?

1 answer

Answer

1057217

2026-05-18 21:25

+ Follow

used in defining goto statement in C++.

tells the program which part of the code it should skip to.

example:

void main()

{

x: // This is the label

cout<<"\n Wikipedia rocks" ;

cout<<"\n google rocks" ;

goto x; // starts executing from x:

getch();

}

// Warning!! this loop will be infinite, plz do not run it, its only for example sake!!!

ReportLike(0ShareFavorite

Copyright © 2026 eLLeNow.com All Rights Reserved.