Anyone who is dealing with large quantities of data should have a good understanding of the structure of data. Data structuring is the process of organizing data in order to make it easier for it to be accessed and utilized by software programs. There are a variety of ways to structure data, however the most popular are dictionaries, arrays and linked lists. Each of them has its own strengths and weaknesses, therefore it is crucial to comprehend each one is the best for your particular needs.
Linear Data Structures
Depending on the programming language used, linear data structures can differ in their allocation of memory internal structure, as well as how fundamental operations (traversal, retrieval, insertion, deletion) are carried out. A good example of a linear data structure is an array that has its elements stored in multiple memory locations that are contiguous, where each element is accessible by using an index that starts at 0. They are useful for algorithms that require sequential access to data. They are great to store lists of information (like dates or addresses) and performing mathematical computations.
Non-Linear Data Structures
A non-linear data structure is a tree which organizes data in a hierarchical manner. Each record (or node) in a tree is connected to one or more succeeding records by a parent/child relation. Each child’s record may contain information or pointers that connect to other records in the tree. An excellent example of a tree is a family tree which has its primary piece of data at the top, and branches out into children, grandchildren and others.