Data Structure

data structure and algorithm

What is Data Structure and Abstract Data Types?

June 29, 2020

The study of data structure therefore involves two complementary goals. The first goal is to identify and develop the useful mathematical entities and operations. The second goal is to determine representation for those abstract entities and to implement the abstract operations. In data structure that exit in c the array and structure, we describe the […]

Read More

How to Represent Stack in C – Data Structure

June 22, 2020

The Stack provides for the insertion and deletion of items, so that a stack is a dynamic, constantly changing object. #define MAXSIZE 100struct stack { int items[MAXSIZE]; int top;}; Note: If the value of s-top is 4 there are five elements on the stack i.e s.item[0], s.items[1], s.items[2], s.items[3], s.items[4] When the stack is popped, […]

Read More
tower of hanoi

Tower of Hanoi Problem (TOH) with Recursive Algorithm

June 14, 2020

TOH ( Tower of Hanoi) is a mathematical game or puzzle. It consists of 3 pegs A, B and C. N Disks of different diameters are placed on peg A so that a larger disk is always below a smaller disk. The aim is to move the N disks to peg C using peg B […]

Read More
Non-Linear Data Structure and Algorithm

Non-Linear Data Structure and Algorithm

May 24, 2020

The implementations of Stacks and Queues from linear data structures.  They cannot represent data items possessing hierarchical relationship such as between the grandfather and his descendants and in turns their descendants and so on. We need a non-linear data structure to deal with such an application in a real-life situation. Trees and graphs are two […]

Read More
Binary Trees

Binary Trees and It’s Different Types

May 23, 2020

A binary tree is a finite set of elements that is either empty or is partitioned into three disjoint subsets. The first subset contains a single element called the root of the tree. The other two subsets are themselves binary trees, called the left and right subtrees of the original tree. Left or right subtree […]

Read More
data structure

What is Data Structure? Why Do We Require This?

July 28, 2019

Question: What is Data Structure? Data is the basic factor entity that is utilized in calculation or manipulation. There are two different type of data numerical and alpha-numerical data and these two data type defines that the nature of data item under that goes some operations, like integer floating point data character constant and such other data items […]

Read More
data types

Difference Between Primitive and Non-Primitive Data Types

July 22, 2019

Primitive data type: In simple terms “data type” and “primitive data type” are simply known and used as interchangeable variables. Primitive data types are predefined types of data, which are supported by the programming language. For example, integer, character, and string are all primitive data types. Non-primitive data type: Non-primitive data types are not defined by the programming language, but are instead created […]

Read More