# D.S & Algorithm

## Searching in Data Structure

Searching A process of finding an element from list of element stored any order/randomly. Searching is of two types Linear search Binary search Linear search Steps Each element of the array read one by one segmentally & compared with the desired element. Successful-element available Unsuccessful-all element is read and the desired element not found. n-no. …

## Quicksort

Quicksort Quicksort is depended on the divide and conquer technique. Set is reduced by sorting two smallest sets. Steps:Step-1: Identify the key value.Step-2: Scan from R->L stopping at value < key Interchange value & keyStep-3: Scan from L->R stopping at value > key Interchange value & keyStep-4: Continued step 2 & 3 Perform QUICKSORT on the given data: 44 33 …

## Insert element in an array using C

Insert element in an array using C Array for insertion Addition of new element into an array at any specific location. Code : Output

## Delete an element from an array using C

An array of Deletion : Working – Delete an element from an array Program Output : Enter the size of an array = 2 Enter the element 23 12 Enter the location to be deletion = 1 Array after deletion 23

## Conversion of Binary Tree Traversal

Creation of Binary Tree from Preorder to Inorder Steps Scan Preorder traversal from L->R. For each node scanned locate its position in inorder traversal, let the scanned node be x. The node proceeding x in-order from its left subtree and node succeeding it is from its right subtree. Repeat step 1 to 3 for each …

Scroll to Top