Data Structures: how to make them? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

Data Structures: how to make them?

so i want to make my own data structures, but i have some questions, i am using java is there any way to make a Collection system that doesnt use any current system? like ideally id like to make nodes and have a class that stores the nodes, but i cant think of anyway to have multiple nodes without storing them inside of some pre-existing collection like an array.

14th Aug 2018, 1:04 PM
Robert Atkins
Robert Atkins - avatar
2 Answers
+ 1
「HAPPY TO HELP」 thank you for the info, i looked into nodes and now better understand how they relate to each other it has opened a new door, just to make sure i have it right though, a linked list will have a reference to the next node only, a doubly linked list will have a reference to the previous node and next node with the first nodes previous node reference being null and last nodes next reference being null, then when you insert a node in the middle you just update the references of the next and previous nodes at the point of insert?
15th Aug 2018, 1:00 PM
Robert Atkins
Robert Atkins - avatar
0
「HAPPY TO HELP」 easy on a conceptual level, the fun part will be implementation, thanks again for all the help!
15th Aug 2018, 5:40 PM
Robert Atkins
Robert Atkins - avatar