Common Data Structures in Common Lisp

submited by
Style Pass
2024-05-18 23:30:06

We're going to cover creating three different types of data structures in Common Lisp: linked lists, growable vectors, and hash tables.

I'm going to assume knowledge of some Common Lisp, and knowledge of Big-O notation. I know that might be a tall glass of water, but I'm covering knowledge from my whole CS 235 class over ten years after I attended said class in one blog post in Common Lisp and trying to write it in a single Saturday morning, so I'mma need your help here.

We're going to pretend that all the nice data structures Common Lisp gives us are gone from our memory. The only things we'll remember how to do after this rather unfortunate case of amnesia will be structs and simple-arrays. I'm trying to go fast-ish, so you might want to read up on those if you're unfamiliar.

Once we create a new data structure, all of a sudden all the functions and data structures CL provides to do the same thing will come flooding back into our memory. It's like Fifty First Dates only it'll be fifty first data structures.

Leave a Comment