GoLang keywords

Keywords or reserved keywords in a language are words that cannot be used for any purpose other than they are intended to. So, we cannot use them as the variable name or any other identifiers.

There are 25 such keywords in Go Language

continueforimportreturn var

In our Hello world program, too, it can be seen that we have used the three keywords there only. So, it’s safe to say that even the small programs require keywords.

package main
import "fmt"
func main() {
    fmt.Println("Hello World!")

The above program contains three keywords – package, import, and “func“.

We will be looking at all of the keywords in our upcoming posts.

Liked the article? Share this on

Leave a Comment

Your email address will not be published. Required fields are marked *