GoLang Flashcards

1
Q

Concurrency

A

Go has built-in support for concurrency through goroutines and channels, which make it easy to write concurrent programs.
Unlike traditional threading models, goroutines are lightweight and managed by the Go runtime, making it efficient to spawn thousands of them.
Channels provide a safe way for goroutines to communicate and synchronize data.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Static Typing with Type Inference

A

Go is statically typed, meaning variables have predefined types that cannot change.
However, Go also features type inference, allowing developers to omit the type when declaring variables if it can be inferred from the assigned value.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Garbage Collection

A

Go has automatic memory management via garbage collection, which helps prevent memory leaks and simplifies memory management for developers.
Garbage collection in Go is concurrent, meaning it can run concurrently with the application, reducing pause times.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Error Handling

A

Go favors explicit error handling rather than exceptions.
Functions typically return error values alongside the result, and it’s common to check for errors immediately after function calls.
Go’s approach to error handling encourages developers to handle errors explicitly, leading to more robust and predictable code

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Simplicity and Minimalism

A

Go follows a minimalist design philosophy, favoring simplicity and readability.
It has a relatively small standard library compared to some other languages, but it’s designed to be comprehensive and efficient.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q
A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Cross-Platform Support

A

Go is designed to be cross-platform, with compilers available for various operating systems and architectures.
This makes it easy to write Go programs that can run on different platforms without modification.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly