Go Goto Statement

In this tutorial you will learn about the Go Goto Statement and its application with practical example.

Go Goto Statement

In GoLang, goto statement is used to alter the normal execution of a program and transfer control to a labeled statement in the same program. The label is an identifier, it can be any plain text and can be set anywhere in the Go program above or below to goto statement. When a goto statement is encountered, compiler transfers the control to a label: and begin execution from there.

Table Of Contents

Syntax:-

Example:-

Output:-

go_goto_statement

In this tutorial we have learn about the Go Goto Statement and its application with practical example. I hope you will like this tutorial.