Iniciante
Go
Aprenda Go do inicio ao fim. Comece com pacotes, variaveis e controle de fluxo, depois aprofunde-se em structs, interfaces, concorrencia, testes, servidores HTTP, bancos de dados, generics, profiling e publicacao de binarios reais em producao.
20 lições12.3h prático11 idiomas
Comece a aprender de graçaGo curso20 lições, em ordem
- 125 min
Olá, Go
Package mainImportFunc mainFmt.PrintlnGo run - 225 min
Variáveis e Tipos
Var declarationShort declaration :=IntFloat64StringBool+2 - 330 min
Fluxo de Controle: if e for
IfElse ifElseFor loopFor as whileInfinite for+2 - 430 min
Funções
Func keywordParametersReturn valuesMultiple return valuesNamed return valuesBlank identifier - 535 min
Slices e Maps
Slice literalAppendLenIndexingRangeMap literal+2 - 640 min
Projeto Final de CLI Minimalista
Os.ArgsStrconv.AtoiError handling with if err != nilOs.ExitGo buildPutting it together - 735 min
Structs e Ponteiros
Struct definitionField accessZero values for structsPointer types& and * operatorsPointer receivers vs value receivers+1 - 835 min
Métodos e Interfaces
Method declarationReceiver typesPointer vs value receiversInterface definitionImplicit interface satisfactionSmall interfaces+1 - 935 min
Tratamento de Erros
Error interfaceFmt.Errorf with %wErrors.IsErrors.AsCustom error typesPanic vs error+1 - 1040 min
Goroutines e Canais
The go keywordGoroutine lifetimeUnbuffered channelsBuffered channelsSend and receiveRange over channel+1 - 1145 min
Padrões de Concorrência
Select statementContext.Context for cancellationSync.WaitGroupSync.MutexWorker pool patternFan-out fan-in idea - 1240 min
Um Tour pela Biblioteca Padrão
FmtStringsStrconvTimeOsBufio+1 - 1340 min
Testes e Benchmarks
Go testTesting.TTable-driven testsT.Run subtestsTesting.B benchmarks_test.go file naming+1 - 1435 min
Módulos e Estrutura de Projeto
Go mod initGo.mod and go.sumImport pathsPackage vs moduleInternal/ folderCmd/ layout+1 - 1545 min
Servidores HTTP
Net/httpHttp.HandleFuncHttp.ServerJSON responsesRequest routingMiddleware via http.Handler wrapping+1 - 1645 min
Bancos de dados com database/sql
Database/sql packageDriver importsSql.Open and sql.DB poolExec vs Query vs QueryRowPrepared statementsScanning rows+1 - 1735 min
Genéricos
Type parameters with [T any]ConstraintsComparableTilde approximation ~intGeneric Map and FilterWhen generics help, when they do not - 1840 min
Desempenho e Criação de Perfis
Go test -benchPprof CPU and heap profilesEscape analysis with -gcflags=-mAvoiding unnecessary allocationsPreallocating slicesSync.Pool intuition - 1940 min
Padrões de Projeto em Go
Functional options patternRepository patternDependency injection via interfacesContext propagation through call stacksConstructor functions - 2045 min
Implantação e Produção
CGO_ENABLED=0 static binariesCross-compile with GOOS and GOARCHGraceful shutdown with http.Server and signal.NotifyContextMinimal Dockerfile with scratch or distrolessReading config from environment variables
Aprenda Go no seu idioma
Cada lição, quiz e resposta do tutor aparece no seu idioma. O tutor de IA responde no idioma em que você pergunta.
