Data structures in Java part — 1

Sanagavarupu Gopichand
2 min readJun 9, 2024

What is a Data structure ?

A Data structure is an organization or arrangement of data in computer memory. Sometimes this arrangement may be subjected in computer disk as well. This storage format was chosen for efficient access to data. A data structure is also a collection of data values which has relations among them and the functions or operations that can be applied to the data.

An efficient data structure can handle lots of data and helps to increase the performance and projected designing efficient algorithm. The implementation of a data structure usually requires writing a set of methods that can be manipulate the object instance.

— Linus Torvalds once said

“ A bad programmers worry about the code. Good programmers worry about data structures and their relationships.”

There are two types of data structures present Java. They are

  1. Primitive data structures
  2. Non-Primitive data structures

Primitive data structures:

These are the basic built-In data structures in java. They are included by

  1. Byte
  2. Short
  3. Int
  4. Float
  5. Char
  6. Boolean
  7. Long
  8. Double

Non — primitive data structure:

A non-primitive data structure is record in structure. They are more complex and composed of primitive information. These are segregated into two categories they are.

Linear Data Structure

  1. Arrays
  2. Stacks
  3. Queues
  4. Linked List

Non — Linear Data Structure

  1. Trees
  2. Graph
  3. Heap
  4. Hash

I will explain each every data structure in coming articles

References:

https://en.wikipedia.org/wiki/Data_structure

--

--