##### ###### ##### ### # # ### # # ###### ## ## ## ## ## ## ## # # # # # ## ##### #### ##### # # # # # # # #### ## # ## ## ## ## # # # # # ## ## # ###### ## ### # ### # ######
##### ###### ##### ### # # ### # # ###### ## ## ## ## ## ## ## # # # # # ## ##### #### ##### # # # # # # # #### ## # ## ## ## ## # # # # # ## ## # ###### ## ### # ### # ######
##### ###### ##### ### # # ### # # ###### ## ## ## ## ## ## ## # # # # # ## ##### #### ##### # # # # # # # #### ## # ## ## ## ## # # # # # ## ## # ###### ## ### # ### # ######
Work with collections using arrays and slices
Welcome to Arrays & Slices
Fixed-size collections
Setting values at creation
Using indices
Test your knowledge
The len function
Looping through elements
Copy behavior
Test your knowledge
Flexible collections
Creating slices directly
Pre-allocating capacity
Test your knowledge
Two different measures
How slices work
Creating slices from arrays
Omitting bounds
Test your knowledge
Growing slices
Combining slices
Test your knowledge
The copy function
Slices without data
Test your knowledge
Common mistakes
Delete from slices
Add at position
Test your knowledge
Slices of slices
Dynamic allocation
The sort package
Test your knowledge
Finding elements
Selecting elements
Flip the order
Test your knowledge
Avoiding leaks
Passing slices around
Test your knowledge
Go 1.21+ helpers
Equality checks
Idiomatic slice usage
Looking ahead
Key takeaways