Let's Learn Algorithms - What is a queue and how do I implement one?
Learn what a queue is with real world examples, and then follow along as we learn to implement a queue using Go, a programming language created by Google. The queue created in this video has a slight memory issue that is a byproduct of slices are created in Go. If you use it long enough, chances are you will run out of memory. I still opted to use this approach because it is much easier to understand and it is fine for most programs that don't use a queue indefinitely. For an idea of how to create a safer Queue backed by a Linked List (implemented by the container/list package) check out my blog post that covers generating code (specifically queues!) in Go - https://www.calhoun.io/using-code-generation-to-survive-without-generics-in-go/ If you enjoyed this content, please check out https://www.calhoun.io#mailing-list-form to join my mailing list and get notified when I release new videos and articles like this one. I send out emails about once every week letting everyone know about new videos and articles I published, and occasionally send an email about new courses or books I am writing. I promise, I won't spam or sell your email address!
Download
0 formatsNo download links available.