Skip to content

Commit 4539c51

Browse files
Create Introduction to Data Structures.md
Created an introductory guide to data structures in Java, covering primitive and non-primitive types, linear and non-linear structures, with detailed explanations and examples for each category.
1 parent 4b50a97 commit 4539c51

File tree

1 file changed

+46
-0
lines changed

1 file changed

+46
-0
lines changed

Diff for: Introduction to Data Structures.md

+46
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
## What are Data Structures in Java?
2+
3+
Data Structure in Java is defined as the collection of data pieces that offer an effective means of storing and organizing data in a computer. Linked List, Stack, Queue, and arrays are a few examples of Java data structures.
4+
5+
There are two types of Data Structures:-
6+
7+
1. **Primitive Data Structures**
8+
2. **Non-primitive Data Structures**
9+
10+
### Primitive Data Structures
11+
Primitive data Structures are also called Primitive Data Types. `byte`, `short`, `int`, `float`, `char`, `boolean`, `long`, and `double` are primitive Data types.
12+
13+
### Non-primitive Data Structures
14+
Non-primitive Data Structures are of two types:-
15+
16+
1. **Linear Data Structures**
17+
2. **Non-linear Data Structures**
18+
19+
### Linear Data Structures
20+
The elements arranged in a linear fashion are called Linear Data Structures. Here, each element is connected to one other element only. Linear Data Structures are as follows:
21+
22+
- **Arrays**
23+
- Single dimensional Array
24+
- Multidimensional Array
25+
- **Stack**
26+
- **Queue**
27+
- **Linked List**
28+
- Singly-linked list
29+
- Doubly Linked list
30+
- Circular Linked List
31+
32+
### Non-Linear Data Structures
33+
The elements arranged in a non-linear fashion are called Non-Linear Data Structures. Here, each element is connected to n-other elements. Non-Linear Data Structures are as follows:
34+
35+
- **Trees**
36+
- Binary Tree
37+
- Binary Search Tree
38+
- AVL Tree
39+
- Red-Black Tree
40+
- **Graph**
41+
- **Heap**
42+
- MaxHeap
43+
- MinHeap
44+
- **Hash**
45+
- HashSet
46+
- HashMap

0 commit comments

Comments
 (0)