Lists vs Vectors in Clojure

One of the projects I’m working on for Gluino has me thinking about data structures again. Data structures are ways of storing data in memory (either program memory or on disk), and the choice can be significant. I’m working on a list of requests with scores and values. This list grows dynamically as items enter and leave it. It could contain 0, 1, or many items. Let’s discuss the implementation of these structures in a more common programming language better to understand the difference between a list and a vector. Simply put, a vector is like an array of memory, whereas a list is more similar to a linked list. Here is some C code creating an array, which is akin to a vector: ...

May 21, 2024 · zacharyc