DEV Community

Anastasiia Ogneva
Anastasiia Ogneva

Posted on

Singly and doubly linked lists in C and C++: general description and 4 implementations

Developers get questions over and over again (on Stack Overflow and other sites) about implementing single-linked/double-linked lists in C and C++. They also ask how to perform this or that operation on a list.

Image description

Here is a step-by-step guide with code examples on creating lists:

A general description of linked lists as data structures
Implementation of a singly linked list in C
Implementation of a singly linked list in C++
Implementation of a doubly linked list in C
Implementation of a doubly linked list in C++

I hope you find this list useful. Of course, it's good to create your own list while learning the code. However, many people have the same questions about lists' implementation. So, enjoy!

Top comments (0)