### Data Structure and Algorithms Tutorial

## Data:

Raw facts and figures are known as data. We get information from data after processing data.## Data Structure:

The data structure is a way of storing and organizing data in a system so that it can be used efficiently.### Types of Data Structure:

There are two types of Data Structure**Linear Data Structure**

Arrays, Stacks, Queues and Linked List are Linear Data Structures.**Non-Linear Data Structure**

Trees, Graphs, Tables and all other are Non-Linear Data Structures.

We can also distinguish data structure according to there implementation

There are also two types of Data structure according to there implementation

**Physical Data Structure**:

Physical data structure means how data actually stored in memory. Arrays and Linked Lists are the examples of Physical data structures because every other data structure like the stack, queue, trees, graphs etc are actually implemented by using arrays or linked lists.**Logical Data Structure**:

Logical data structure means how data is shown to the user. Stacks, Queues, Trees, Graphs etc are examples of the logical data structure.

### Operations on Data Structures:

**Traversing**: Traverse each record at least one time.**Insertion**: Inserting new data.**Deletion**: Removing data.**Merging**: Merge two files into a single one.**Searching**: Find a record using a key value.**Sorting**: Arange the data in assending or desending order.

###
**Abstract Data type:**

A mathematical model with a collection of operation defined on that model is called abstract data type. It is known as abstract because internal representation is hidden from the user. Implementation of abstract data types is also known as Data Structure.## Algorithm:

Series of steps or step by step procedure to solve a particular problem.Basically, there are three parts of Algorithms

- Input
- Process
- Output

### Representation:

There are two ways to represent an algorithm**Flowcharts**:

Graphical representation of an algorithm.**Pseudocode**:

Representation of an algorithm in a language near to English.

#### Factors of a Good Algorithm:

- Time
- Memory usage
- Complexity
- General
- Termination Criteria
- Sequence

## Comments

## Post a Comment