This is the repository about a Go Specialization done in Coursera, the topics are many, this is a short summary about...
-
Basics:
- Why go? - Compiled VS Interpreted - Efficiency vs easy to use - Garbage collection - OOP -> No classes -> Structs - Concurrency / Parallelism - Workspaces / Directory hierachy / Packages - Pointers - Variable Scopes - Stack vs Heap - Comments / Prints / Inputs / Outputs - Types in Go - Groups of data (Slices, hash tables. structs) - Protocols and formats - Files
-
Mid-level:
- Functions - Parameters - Return values (And multiple returns) - Call by value and references - Passing arrays and arguments - Passing array pointer - Good practices - Variables as functions - Funcstions as arguments - Anonymous functions - Functions as return values - Functions defining a function - Variable argument number - Variadic slice argument - Deferred function calls - Deffered call arguments
-
Advances
- Object Orientation in GO - Classes / Objects - Encapsulation - Associating methods with data - Implicid method arguments - Structs as "classes" and methods - Controlling access to structs - Point and large receivers (Not need to reference) - Using pointer receivers - Interfaces for abstraction - Inheritance (Not sopported in GO) (Overriding) - Concrete VS Interfaces Types - Interface values - Nil values, nil dynamic values and nil interface value - Why use interfaces? -> Empty interfaces -> Canceling Types Diferences -> Type Assertion for Desambiguation -> Type Switch -> Error Interfaces - Handing ERRORS
-
Go special: Concurrency
- Why use concurrency? - Moore's law -> Power wall -> Dynamic power -> Multi-core systems -> Concurrent execution -> Concurrency vs Parallelism - Concurrent programming -> Hiding latency -> Hardware mapping in GO - Processes -> Scheduling -> Context Switch -> Threads VS Processes - GO Routines -> Go Routines Scheduler -> Interleaving -> Race conditions - Exiting a GO Routine -> Early exit -> Delayed exit - Synchonization -> Sync wait groups -> Communicating GoR -> Channels -> Buffer in channels -> Blocking -> channels capacity/buffer -> Blocking -> Receiving - Iterating through a channel -> Receiving multiple GoR chanels - Select statement -> Select send or receive -> Select with abort channel -> Default select - Mutual exclusion -> Mutex -> Sync.Mutex -> Mutex Methods - Sync initialization - Deadlock -> Deadlock detection