C++ Data structures

Open-source C++ projects categorized as Data structures

Top 23 C++ Data structure Projects

  • Protobuf

    Protocol Buffers - Google's data interchange format

    Project mention: Create Production-Ready SDKs With gRPC Gateway | dev.to | 2023-12-08

    gRPC Gateway is a protoc plugin that reads gRPC service definitions and generates a reverse proxy server that translates a RESTful JSON API into gRPC.

  • C-Plus-Plus

    Collection of various algorithms in mathematics, machine learning, computer science and physics implemented in C++ for educational purposes.

  • JetBrains Dev Survey

    What’s up with the C++ ecosystem in 2023? JetBrains Developer Ecosystem Survey 2023 has given us many interesting insights. The Embedded (37%) and Games (39%) industries are already working with C++20, developers are incorporating static analysis in their CI, and ChatGPT usage among coders is flourishing. Read on for more!

  • Apache Thrift

    Apache Thrift

  • cp-algorithms

    Algorithm and data structure articles for https://cp-algorithms.com (based on http://e-maxx.ru)

    Project mention: Do you know of any helpful sources like this for leetcode? | /r/csMajors | 2023-10-02

    I've been learning alot from this git repository: https://cp-algorithms.com/ . Do you know of any of any sources or repositories like this that help with Leetcode or problem solving?

  • algorithms_and_data_structures

    180+ Algorithm & Data Structure Problems using C++

  • NumCpp

    C++ implementation of the Python Numpy library

  • kactl

    KTH Algorithm Competition Template Library (... eller KTHs AC-tillverkande lapp)

    Project mention: Popcount walks: next, previous, toward and nearest | news.ycombinator.com | 2023-11-14

    As a competitive programmer, I’ve seen similar ‘magic’ tricks here: https://github.com/kth-competitive-programming/kactl/blob/ma... (page 23)

  • WorkOS

    The modern API for authentication & user identity. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.

  • immer

    Postmodern immutable and persistent data structures for C++ — value semantics at scale (by arximboldi)

    Project mention: Text Editor Data Structures: Rethinking Undo | news.ycombinator.com | 2023-12-11

    I've been working on an editor (not text) in C++ and pretty early got into undo/redo. I went down the route of doIt/undoIt for commands but that quickly got old. There was both the extra work needed to implement undo separately for every operation, but also the nagging feeling that the undo operation for some operation wasn't implemented correctly.

    In the end, I switched to representing the entire document state using persistent data structures (using the immer library). This vastly simplified things and implementing undo/redo becomes absolutely trivial when using persistent data structures. It's probably not something that is suitable for all domains, but worth checking out.

    https://github.com/arximboldi/immer

  • Coding

    Data Structures and Algorithms (DSA) Preparation sheet

    Project mention: Just started reading this book "Groking the coding interview" found this paragraph worth sharing | /r/developersIndia | 2023-05-18
  • etl

    Embedded Template Library

    Project mention: Modern C++ Programming Course | news.ycombinator.com | 2023-11-28

    If you can't use the STL because of exceptions: https://www.etlcpp.com/

  • DataStructures-Algorithms

    This repo contains links of resources, theory subjects content and DSA questions & their solution for interview preparation from different websites like geeksforgeeks, leetcode, etc.

  • robin-map

    C++ implementation of a fast hash map and hash set using robin hood hashing

    Project mention: Factor is faster than Zig | news.ycombinator.com | 2023-11-10

    In my example the table stores the hash codes themselves instead of the keys (because the hash function is invertible)

    Oh, I see, right. If determining the home bucket is trivial, then the back-shifting method is great. The issue is just that it’s not as much of a general-purpose solution as it may initially seem.

    “With a different algorithm (Robin Hood or bidirectional linear probing), the load factor can be kept well over 90% with good performance, as the benchmarks in the same repo demonstrate.”

    I’ve seen the 90% claim made several times in literature on Robin Hood hash tables. In my experience, the claim is a bit exaggerated, although I suppose it depends on what our idea of “good performance” is. See these benchmarks, which again go up to a maximum load factor of 0.95 (Although boost and Absl forcibly grow/rehash at 0.85-0.9):

    https://strong-starlight-4ea0ed.netlify.app/

    Tsl, Martinus, and CC are all Robin Hood tables (https://github.com/Tessil/robin-map, https://github.com/martinus/robin-hood-hashing, and https://github.com/JacksonAllan/CC, respectively). Absl and Boost are the well-known SIMD-based hash tables. Khash (https://github.com/attractivechaos/klib/blob/master/khash.h) is, I think, an ordinary open-addressing table using quadratic probing. Fastmap is a new, yet-to-be-published design that is fundamentally similar to bytell (https://www.youtube.com/watch?v=M2fKMP47slQ) but also incorporates some aspects of the aforementioned SIMD maps (it caches a 4-bit fragment of the hash code to avoid most key comparisons).

    As you can see, all the Robin Hood maps spike upwards dramatically as the load factor gets high, becoming as much as 5-6 times slower at 0.95 vs 0.5 in one of the benchmarks (uint64_t key, 256-bit struct value: Total time to erase 1000 existing elements with N elements in map). Only the SIMD maps (with Boost being the better performer) and Fastmap appear mostly immune to load factor in all benchmarks, although the SIMD maps do - I believe - use tombstones for deletion.

    I’ve only read briefly about bi-directional linear probing – never experimented with it.

  • stdgpu

    stdgpu: Efficient STL-like Data Structures on the GPU

  • PGM-index

    🏅State-of-the-art learned data structure that enables fast lookup, predecessor, range searches and updates in arrays of billions of items using orders of magnitude less space than traditional indexes

    Project mention: Self-indexing RDBMS? Could AI help? | /r/Database | 2023-04-26

    PGM Index

  • Hopscotch map

    C++ implementation of a fast hash map and hash set using hopscotch hashing

  • megahit

    Ultra-fast and memory-efficient (meta-)genome assembler

  • ewig

    The eternal text editor — Didactic Ersatz Emacs to show immutable data-structures and the single-atom architecture

    Project mention: Text Editor Data Structures | news.ycombinator.com | 2023-06-13

    You might be interested in ewig and immer by Juan Pedro Bolivar Puente:

    https://github.com/arximboldi/ewig

    https://github.com/arximboldi/immer

    See the author instantly opening a ~1GB text file with async loading, paging through, copying/pasting, and undoing/redoing in their prototype “ewig” text editor about 27 minutes into their talk here:

    https://m.youtube.com/watch?v=sPhpelUfu8Q

    It’s backed by a “vector of vectors” data structure called a relaxed radix balanced tree:

    https://infoscience.epfl.ch/record/169879/files/RMTrees.pdf

    That original paper has seen lots of attention and attempts at performance improvements, such as:

    https://hypirion.com/musings/thesis

    https://github.com/hyPiRion/c-rrb

  • ordered-map

    C++ hash map and hash set which preserve the order of insertion

  • algorithms

    Algorithms & Data Structures & Computer Science studies (by imteekay)

  • Leetcode

    This Repository Contains All My Solved Leetcode Problems. (by knockcat)

  • Data-Structures-and-Algorithms-in-cpp

    This repository is in development phase and will soon provide you with c++ code of various data structures and algorithms

  • Daily-Coding-DS-ALGO-Practice

    A open source project🚀 for bringing all interview💥💥 and competative📘 programming💥💥 question under one repo📐📐

  • ExcaliburHash

    Excalibur Hash is a high-speed hash map and hash set, ideal for performance-critical uses like video games

    Project mention: Excalibur Hash is a high-speed hash map and hash set | news.ycombinator.com | 2024-01-10
  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

NOTE: The open source projects on this list are ordered by number of github stars. The number of mentions indicates repo mentiontions in the last 12 Months or since we started tracking (Dec 2020). The latest post mention was on 2024-01-10.

C++ Data structures related posts

Index

What are some of the best open-source Data structure projects in C++? This list will help you:

Project Stars
1 Protobuf 62,903
2 C-Plus-Plus 28,624
3 Apache Thrift 10,069
4 cp-algorithms 6,142
5 algorithms_and_data_structures 5,706
6 NumCpp 3,288
7 kactl 2,410
8 immer 2,400
9 Coding 2,072
10 etl 1,900
11 DataStructures-Algorithms 1,568
12 robin-map 1,120
13 stdgpu 1,047
14 PGM-index 735
15 Hopscotch map 689
16 megahit 542
17 ewig 517
18 ordered-map 490
19 algorithms 486
20 Leetcode 457
21 Data-Structures-and-Algorithms-in-cpp 353
22 Daily-Coding-DS-ALGO-Practice 314
23 ExcaliburHash 292
ChatGPT with full context of any GitHub repo.
Onboard AI learns any GitHub repo in minutes and lets you chat with it to locate functionality, understand different parts, and generate new code. Use it for free at app.getonboardai.com.
app.getonboardai.com