UNIT-2 DATA STRUCTURES A data structure is a particular way of storing and organizing data in a computer so that it can be used efficiently. - Different kinds of data structures are suited to different kinds of applications, and some are highly specialized to specific tasks. - The data structure can be classified into following two types:

UNIT-2 DATA STRUCTURES Simple Data Structure : These data structures are normally built from primitive data types like integers, - floats, characters. For example arrays and structure. Compound Data Structure: simple data structures can be combined in various ways to form more complex structure called compound structures. Linked Lists, tack, Queues and Trees

Data Structure Arrays - Data structure array is defined as linear sequence of finite number of objects of same type with following - set of operation: I Creating: defining an array of required size Insertion: addition of a new data element in the in the array Deletion: removal of a data element from the array

Data Structure Arrays Searching: searching for the specified data from the array Traversing: processing all the data elements of the array Sorting : arranging data elements of the array in increasing or decreasing order Merging : combining elements of two similar types of arrays to form a new array of same type

Data Structure Arrays In C++ an array can be defined as Datatype arrayname[size] Where size deines the maximum numberr of elements can be hold in the array. For example - float b[10://b is an array which can store maximum 10 float values - int c[5];

Thanks!

45 lessons,

8h 7m

Enroll

24

✕Download

Jitendra jangir

B.tech from CSE branch ,having more than 4 years teaching experience ,my courses will help you to understand different programming languages

U

Unacademy user

MANASHYA GUPTA

10 months ago

Nice sir

5

Reply

Mukul Sharma

10 months ago

Thanks