You are on page 1of 1

A data type is an attribute associated with a piece of data that tells a computer system how to

interpret its value. Understanding data types ensures that data is collected in the preferred format
and the value of each property is as expected.

A data structure is a specialized format for organizing, processing, retrieving and storing data. There
are several basic and advanced types of data structures, all designed to arrange data to suit a specific
purpose. Data structures make it easy for users to access and work with the data they need in
appropriate ways.

Abstract Data type (ADT) is a type (or class) for objects whose behavior is defined by a set of values
and a set of operations. The definition of ADT only mentions what operations are to be performed but
not how these operations will be implemented.

An algorithm is not computer code; it's written in plain English and may be in the form of a flowchart
with shapes and arrows, a numbered list, or pseudocode (a semi-programming language). It doesn't
beat around the bush. It's very clear and efficient, and it has a start, middle, and end.

Types of data structures

Arrays: A collection of elements stored in contiguous memory locations, accessible using indices.
Provides fast access but may have limitations on size.

Linked Lists: Elements (nodes) are linked together through pointers, allowing dynamic size and
efficient insertions/deletions but slower access.

Stacks: Follows the Last-In-First-Out (LIFO) principle, where elements are added and removed from
the same end. Useful for managing function calls and maintaining state.

Queues: Follows the First-In-First-Out (FIFO) principle, where elements are added at the rear and
removed from the front. Ideal for task scheduling and resource allocation.

Trees: Hierarchical structures with a root node and child nodes. Common types include binary trees,
binary search trees, AVL trees, etc. Used for efficient searching, sorting, and data organization.

Graphs: Consist of nodes connected by edges. Used to model complex relationships and solve
problems like network routing, shortest path, and social network analysis.

You might also like