Skip to content

learn-something-new/go-slices

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Slices

logo

A very short example of slices in Go. Copied from my examples of common data structures, I am using the stack as a way to implement slices.

Table of Contents

Arrays

A stack built with a traditional array. You will notice this as a fixed size.

Copy

A stack built with slices implementing the copy method. This is more efficient than a traditional array as it allows you to easily grow the array by making larger arrays and copying your contents over.

Append

A stack built with append. Append allows us to grow the array as we need, using as little memory as possible.

##License This tool is protected by the GNU General Public License v2.

Copyright Jeffrey Hann 2014

About

A basic example of arrays and slices in go.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages