What is Golang and How to install it?

What is Go?

Go is a procedural programming language. It was developed in 2007 by Robert Griesemer, Rob Pike, and Ken Thompson at Google but launched in 2009 as an open-source programming language. Programs are assembled by using packages, for efficient management of dependencies.


This language also supports the environment adopting patterns alike to dynamic languages. For eg., type inference (y: = 0 is a valid declaration of a variable y of type float).

Why Go?

Go language is an effort to combine the ease of programming of an interpreted, dynamically typed language with the efficiency and safety of a statically typed, compiled language. It also aims to be modern, with support for networked and multicore computing.

Windows.

Here, we will discuss, how we install the Golang in our system such as Linux, Windows, macOS.

Firstly, Windows because there are many users who use windows than Linux(best OS for developer) and macOS.

Step-1) Download the Golang Binary distribution(A distribution of software containing executable binaries, without source code.)


Step-2) Double click on the downloaded file and click on "Run".


Step-3) Click "Next".

Step-4) Select the installation folder and click "Next".

Step-5) Click the "Finish" when the installation is completed.

Step-6) Once the installation is complete then, you have to verify that with version.
go version

That`s it for windows guys.

Linux or Debian.

Now, move to our lovely community, yes its Linux or Ubuntu Debian. Here we just have to some command to install the Golang.

Step-1) Write the command below to download the installer of Golang.
wget -q https://storage.googleapis.com/golang/getgo/installer_linux
Step-2) Give the required permission to it.
chmod +x installer_linux
 Step-3) Move to the installer.
./installer_linux
Step-4) Now run below, to persist the new environment variables to your current session, or open a new shell prompt(that will see the last line after run the Step-3).
source /home/<yourName>/.bash_profile
Step-5) Check the Golang and version using the below command.
go version
That`s it, If you want to download the Golang from the official website then install it, So you have to follow these steps.

macOS.

It`s time for macOS to install the Golang.

Step-1) Click on the link to download.


Step-2) Click on "Continue" for installation process.


Step-3) Click on "install" to install it and then enter your system password.

Step-4) Close because now the installation is successfully completed.

Step-5) Check the Golang and version using the below command.
go version
Yey, installation is completed.

So, now you have to learn the Go programming language. I preferred docs or TutorialPoint(If you want to cover the main point and step-by-step) to learn that.

Resources.
I hope you like this article, So let's start with Go!

Comments

Popular posts from this blog

How Network Communications Occurs? | OSI Model.

Languages for AI

Why We Learn Linux?