Introduction to beginners learn to go

Overview

For-learning-Go-Tutorial

准备写一本Go的书针对初学者快速入门开发和使用go!

学习Go语言需要去了解Go的特性,然后在深入的去实践,如果你想使用Go语言写出Go味道的程序,那么你就需要付出努力去实践了! 先来了解下Go语言为何创造出来的历史吧,Go 语言是由谷歌公司在 2007 年开始开发的一门语言,目的是能在多核心时代高效编写网络应用程序。Go 语言的创始人 Robert Griesemer、Rob Pike 和 Ken Thompson 都是在计算机发展过程中作出过重要贡献的人。 自从 2009 年 11 月正式公开发布后,Go 语言迅速席卷了整个互联网后端开发领域,其社区里不断涌现出类似 vitess、Docker、etcd、Consul 等重量级的开源项目。

Go是一种编译型语言,一种并发的、带垃圾回收的、快速编译的语言。它具有以下特点:

  • 它可以在一台计算机上用几秒钟的时间编译一个大型的Go程序。
  • Go为软件构造提供了一种模型,它使依赖分析更加容易,且避免了大部分C风格include文件与库的开头。
  • Go是静态类型的语言,它的类型系统没有层级。因此用户不需要在定义类型之间的关系上花费时间,这样感觉起来比典型的面向对象语言更轻量级。
  • Go完全是垃圾回收型的语言,并为并发执行与通信提供了基本的支持。

为了获得最佳的运行性能,GO语言被设计成一门静态编译型的语言,而不是动态解释型语言,这里我对静态编译型的语言和动态解释型语言做个简单的介绍,方便初学Go语言的新人理解。

1.静态编译型的语言

静态类型语言是指在编译时变量的数据类型即可确定的语言,多数静态类型语言要求在使用变量之前必须声明数据类型,某些具有类型推导能力的现代语言可能能够部分减轻这个要求. 并且通过编译器(compiler)将源代码编译成机器码,之后才能执行的语言。一般需经过编译(compile)、链接(linker)这两个步骤。编译是把源代码编译成机器码,链接是把各个模块的机器码和依赖库串连起来生成可执行文件。

代表语言:Java,Go,C

2.动态解释型语言

动态类型语言是在运行 时确定数据类型的语言。变量使用之前不需要类型声明,通常变量的类型是被赋值的那个值的类型。解释性语言的程序不需要编译,相比编译型语言省了道工序,解释性语言在运行程序的时候才逐行翻译。

代表语言:JavaScript、Python

Go语言的官方编译器被称为gc,包括编译工具5g,6g.8g,链接工具51,61和81以及文档查看工具godoc.

学习一门语言最好的方式就是去实践,那么我们就从go的例子开始实践吧!

golang编程

觉得此文章不错,支持我的话可以给我star ,!如果有问题可以加我的微信,也可以加入我们的交流群一起交流golang技术!

License

This is free software distributed under the terms of the MIT license

You might also like...
A series of small code snipppets & exercises to learn Go.

Learning-Go A series of small code snipppets & exercises to learn Go. WARNING: During this excercise you will be learning along with me, I am not your

Learn Golang in-depth by solving 15 Quizzes, 10 Exercises and 4 Projects
Learn Golang in-depth by solving 15 Quizzes, 10 Exercises and 4 Projects

Modern Go (Golang) - The Complete Beginners Guide 2021 Learn Go (Golang) in-dept

At this example project, I'm trying to learn Golang with Clean structure and come up with a reusable

Learning Golang Language In Clean Structure At this example project, I'm trying to learn Golang with Clean structure and come up with a reusable, nice

Learn-Nakama - An example project template on how to set up and write custom logic in Nakama server

Nakama Project Template An example project template on how to set up and write c

Golang tutorials - a self-project to learn Go.
Golang tutorials - a self-project to learn Go.

Golang Tutorials a self-project to learn Go. prod by blvnk. Tech With Tim Tutorials Intro to Go created a Hello World program. compiled a Hello World

Go-beginners-guide-project - golang beginners project from tutorialedge.net

Go Beginner's Project Running Locally If you want to run this application locally then run the following commands: $ go run cmd/cli/main.go Build Appl

This is a template project to help beginners learn, or to help developers develop some interesting small projects
This is a template project to help beginners learn, or to help developers develop some interesting small projects

This is a template project to help beginners learn, or to help developers develop some interesting small projects

Learn the Go programming language (Golang) in this step-by-step tutorial course for beginners

Learn the Go programming language (Golang) in this step-by-step tutorial course for beginners. Go is an open source programming language designed at Google that makes it easy to build simple, reliable, and efficient software.

Rps-game-in-go - Learn Go for Beginners Crash Course (Golang)

rps-game-in-go This rock-paper-scissors game was based on the Udemy course "Lear

PHP functions implementation to Golang. This package is for the Go beginners who have developed PHP code before. You can use PHP like functions in your app, module etc. when you add this module to your project.

PHP Functions for Golang - phpfuncs PHP functions implementation to Golang. This package is for the Go beginners who have developed PHP code before. Y

based on go lang build WEB development framework for go lang beginners .

based on go lang build WEB development framework for go lang beginners .

A beginner friendly introduction to prometheus 🔥
A beginner friendly introduction to prometheus 🔥

Prometheus-Basics A beginner friendly introduction to prometheus. Table of Contents What is prometheus ? What are metrics and why is it important ? Ba

This slide deck and supporting material is part of the Introduction to Go training course by Dave Cheney

This slide deck and supporting material is part of the Introduction to Go training course by Dave Cheney.

The Little Go Book is a free introduction to Google's Go programming language
The Little Go Book is a free introduction to Google's Go programming language

The Little Go Book is a free introduction to Google's Go programming language. It's aimed at developers who might not be quite comfortable with the idea of pointers and static typing. It's longer than the other Little books, but hopefully still captures that little feeling.

Crank4go API Gateway Brief Introduction It is a Golang implementation of Crank4j
Crank4go API Gateway Brief Introduction It is a Golang implementation of Crank4j

Crank4go API Gateway Brief Introduction It is a Golang implementation of Crank4j, which derived from Cranker. the follow introduction is quoted from t

A quick introduction to how Apache Kafka works and differs from other messaging systems using an example application.
A quick introduction to how Apache Kafka works and differs from other messaging systems using an example application.

Apache Kafka in 6 minutes A quick introduction to how Apache Kafka works and differs from other messaging systems using an example application. In thi

Server and client implementation of the grpc go libraries to perform unary, client streaming, server streaming and full duplex RPCs from gRPC go introduction

Description This is an implementation of a gRPC client and server that provides route guidance from gRPC Basics: Go tutorial. It demonstrates how to u

Introduction to Go slides

Introduction to Go slides In order to run the slides you need to have the go present tool installed. go get -u golang.org/x/tools/cmd/present Once you

Short basic introduction to Go programming language.
Short basic introduction to Go programming language.

Go, Go! Short basic introduction to Go v1.17.6 programming language Go Logo is Copyright 2018 The Go Authors. All rights reserved. About This work was

Comments
  • Chapt 02. 常量部分 代码问题

    Chapt 02. 常量部分 代码问题

    LINK: https://github.com/KeKe-Li/For-learning-Go-Tutorial/blob/master/src/chapter02/01.0.md#%E5%B8%B8%E9%87%8F

    常量部分

    const x, y int = 1, 2 // 多常量初始化
    const s = "Hello, KeKe!" // 类型推断
    const ( // 常量组
    a, b
    c
    = 10, 20
    bool = false
    )
    
    func main() {
    
    const m = "20"// 未使用用局部常量不会引发编译错误。
    }
    

    常量组部分,代码是否有误?


    Env: GO 1.19.2(初学,不确定是不是新版本go语法规则更改),Windows10, Goland Goland 报错:Line 6 Missing Value in the const declaration 运行时: .\main.go:8:1: syntax error: unexpected =, expecting name

    opened by Xrondev 1
Owner
keke
读书,旅游,拍照,做饭。
keke
Learn the Go programming language (Golang) in this step-by-step tutorial course for beginners

Learn the Go programming language (Golang) in this step-by-step tutorial course for beginners. Go is an open source programming language designed at Google that makes it easy to build simple, reliable, and efficient software.

Burak Tokman 1 Dec 16, 2021
Rps-game-in-go - Learn Go for Beginners Crash Course (Golang)

rps-game-in-go This rock-paper-scissors game was based on the Udemy course "Lear

Mark Yen 0 Mar 20, 2022
This slide deck and supporting material is part of the Introduction to Go training course by Dave Cheney

This slide deck and supporting material is part of the Introduction to Go training course by Dave Cheney.

Dave Cheney 85 Nov 14, 2022
The Little Go Book is a free introduction to Google's Go programming language

The Little Go Book is a free introduction to Google's Go programming language. It's aimed at developers who might not be quite comfortable with the idea of pointers and static typing. It's longer than the other Little books, but hopefully still captures that little feeling.

Dariush Abbasi 13.4k Dec 2, 2022
Learn how to write webapps without a framework in Go.

This is an easy to understand example based tutorial aimed at those who know a little of Go and nothing of webdev and want to learn how to write a webserver in Go. You will create a to do list application as you advance the chapters.

Suraj Patil 3.1k Dec 1, 2022
Building a shoe store with golang to learn more about this language :)

shoestore-go Building a shoe store with golang to learn more about this language :) TODO Create a basic webpage with the pages: home : to show homepag

Bruno B. Melo 4 Jan 24, 2022
The purpose of this project is to learn about go-swagger.

learn-go-swagger The purpose of this project is to learn about go-swagger. Requirements Go go-swagger Setup Run ./scripts/gen-swagger to generate swag

Henrik Christensen 0 Nov 20, 2021
A repository for showcasing my knowledge of the Google Go (2009) programming language, and continuing to learn the language.

Learning Google Golang (programming language) Not to be confused with the Go! programming language by Francis McCabe I don't know very much about the

Sean P. Myrick V19.1.7.2 2 Nov 6, 2022
A repository for showcasing my knowledge of the Go! (2003) programming language, and continuing to learn the language.

Learning Go! (programming language) Not to be confused with Google Golang (2009) I don't know too much about the Go! programming language, but I know

Sean P. Myrick V19.1.7.2 2 Oct 22, 2022
Перевод книги «Learn Go with Tests» на русский язык.

Изучите Go через тестирование Обложка нарисована Denise Форматы для чтения Gitbook EPUB or PDF Доступные переводы English 中文 Português 日本語 한국어 Türkçe

Daniil Maslov 0 Dec 9, 2021