## Are you sure?

This action might not be possible to undo. Are you sure you want to continue?

Set No. 1

IV B.Tech I Semester Supplementary Examinations, February 2007 DATA STRUCTURES THROUGH C (Civil Engineering) Time: 3 hours Max Marks: 80 Answer any FIVE Questions All Questions carry equal marks ⋆⋆⋆⋆⋆ 1. Write a program to ﬁnd the sum of all digits in a given number. Repeat this operation successively until the result is a single digit. [16] 2. (a) Write a C function to add two polynomials. Do not destroy the input. Use linked list implementations. (b) Discuss the time complexity of your program. . 3. (a) Write a ‘C’ Program to convert a preﬁx string to inﬁx string . (b) Consider the following arithmetic expression in preﬁx notation: + + A −∗ $BCD/ + EF∗ GHI Find the equivalent inﬁx form of the above. [16]

[8+8]

4. Give a procedure that uses a stack in order to reverse the elements of a circular queue which are stored in an array. You may assume that call push(X)automatically pushes the value of X onto a stack and call pop pop's a value from the stack and assigns it to X on the other hand. [1 6]

5. (a) What is representation? Describe how a binary tree can be represented using an array. (b) Write C function to create and post order traversal of a binary tree [6+10]

6. (a) What are the advantages of adjacency matrix representation of graphs. (b) Deﬁne spanning tree of an undirected graph. [8+8]

7. (a) Using linear search delete the number 26 from the list of numbers and give the steps. 10,7,17,26,32,92 (b) Write a C program to implement the same. 8. Write an algorithm for quick sort. What is its time complexity. ⋆⋆⋆⋆⋆ [8+8] [16]

1 of 1

Code No: RR410110

Set No. 2

IV B.Tech I Semester Supplementary Examinations, February 2007 DATA STRUCTURES THROUGH C (Civil Engineering) Time: 3 hours Max Marks: 80 Answer any FIVE Questions All Questions carry equal marks ⋆⋆⋆⋆⋆ 1. Write a C program to compute the multiplication of two given matrices. [16]

2. (a) What is a linked list? What are the basic operations that are performed on a linked list. Explain with the help of an example. (b) What are the applications of linked lists? 3. Perform the following tasks using stack primitive operations: (a) Set ’i‘ to the second element from the top of the stack, leaving the stack without its top two elements (b) Given an integer n, set ‘i’ to the nth element from the top of the stack, leaving the stack without its top n elements. [8+8] 4. (a) Mention and explain various types of queues and give an example for each (b) Compare various types of queues. 5. (a) Describe diﬀerent types of trees. (b) Write a C program to implement Binary tree. [6+10] [8+8] [10+4]

6. Diﬀerentiate between spanning tree and minimum spanning tree. Write a C function for minimum spanning tree. [16] 7. (a) Distinguish between linear and binary search methods. (b) Write an algorithm for non-recursive binary search method. 8. Write an algorithm for quick sort. What is its time complexity. ⋆⋆⋆⋆⋆ [8+8] [16]

1 of 1

Code No: RR410110

Set No. 3

IV B.Tech I Semester Supplementary Examinations, February 2007 DATA STRUCTURES THROUGH C (Civil Engineering) Time: 3 hours Max Marks: 80 Answer any FIVE Questions All Questions carry equal marks ⋆⋆⋆⋆⋆ 1. Write a C program to ﬁnd the frequency of a given word and a given character in a line of text. [16] 2. (a) Write an algorithm to implement a circularly linked linear list. (b) Formulate insertion and deletion algorithm for the circularly linked linear list. [6+10] 3. (a) Given a sequence of push and pop operations and an integer representing the size of an array in which a stack is to be implemented. Design an algorithm to determine whether or not overﬂow occurs. The algorithm should not use a stack. (b) Explain what test is required for exceptional conditions in pop operations. [8+8] 4. (a) Mention and explain various types of queues and give an example for each (b) Compare various types of queues. 5. (a) Describe diﬀerent types of trees. (b) Write a C program to implement Binary tree. [6+10] [8+8]

6. (a) What are the advantages of adjacency matrix representation of graphs. (b) Deﬁne spanning tree of an undirected graph. [8+8]

7. (a) Using linear search delete the number 26 from the list of numbers and give the steps. 10,7,17,26,32,92 (b) Write a C program to implement the same. 8. (a) Write an algorithm for selection sort (b) Sort the following numbers using selection sort and give the required steps. 96,31,27,42,34,76,61,10,4 [8+8] ⋆⋆⋆⋆⋆ [8+8]

1 of 1

Code No: RR410110

Set No. 4

IV B.Tech I Semester Supplementary Examinations, February 2007 DATA STRUCTURES THROUGH C (Civil Engineering) Time: 3 hours Max Marks: 80 Answer any FIVE Questions All Questions carry equal marks ⋆⋆⋆⋆⋆ 1. Write a C program for replacing a substring with another string. [16]

2. (a) What is a linked list? What are the basic operations that are performed on a linked list. Explain with the help of an example. (b) What are the applications of linked lists? [10+4]

3. (a) Write a ‘C’ Program to convert an inﬁx expression into preﬁx expression (b) Transform the following expression to preﬁx, using the approach (A + B) ∗ (C$(D − E) + F) − G [8+8]

4. (a) Mention and explain various types of queues and give an example for each (b) Compare various types of queues. 5. Write a C program for creating, inserting and deletion in a Binary tree. 6. (a) What are the advantages of adjacency matrix representation of graphs. (b) Deﬁne spanning tree of an undirected graph. [8+8] [8+8] [16]

7. (a) Using linear search delete the number 17 from the list of numbers and give the steps. 42,12,10,91,17,59. (b) Write a C program to implement the same. 8. (a) compare quick sort and heap sort methods. (b) Explain quick sort method for the elements. 11,51,71,21,61,41,91,31, ⋆⋆⋆⋆⋆ [8+8] [8+8]

1 of 1

- Lecture Plan of DSAuploaded byJasmeet
- Linked Listuploaded byGaneshBalaji Katuri
- DS RAJAuploaded byramumallavarapu
- Programming Prepuploaded bySaurabh Sharma
- Program List XII2011uploaded byGaurvi Arora
- pointers programuploaded byRaj Kumar
- BCA0uploaded byTapamalya Sanyal
- Www Indiabix Com Placement Papers Csc 494uploaded byRatul Chopra
- How to Create Linked List Using Cppuploaded bystratisplaton
- OS Project 2(Final)uploaded byDeepak Kinni
- Introduction IIuploaded bylnteractive
- c0870Data Structureuploaded bySai Shubhankar
- List of Computer Science Practicalsuploaded byAbhinav
- fpl-mcq (1)uploaded byDeepak Rana
- UNIT-2-DS-ITuploaded byjayaprabamca
- Starting Out With Python 3rd Edition Gaddis Test Bankuploaded bya283448622
- RTB901A04_HOMEWORK 1_CAP205_rtb901a04uploaded byPriyanka Sharma
- Yahoo Inc Placement Process Detailsuploaded byKalyan Sagar
- JNTU C syllabusuploaded byrameshscribd
- Lab12 Sorting Handoutuploaded byNico Scheinost
- C language question Answersuploaded byJatinder ghuman
- chapter_09.pdfuploaded byJohn Yang
- Psp3uploaded bychinraj956
- java programminguploaded byapi-389758195
- Problem Set 2 Soluploaded bysristisagar
- FM_Reportuploaded byrockyrr
- Algorithm and Data Structureuploaded byGuruKPO
- Questionsuploaded byapi-3701299
- Data Parallel Algorithmsuploaded bymilhousevvp
- 8.Quick Sortuploaded byHaris Muhibic

- 42 Mca Nr Programming in Javauploaded bySrinivasa Rao G
- r6 42 Mca Advanced Java Programming Set1uploaded bySrinivasa Rao G
- 43-Mca-Or-Design and Analysis of Algorithmuploaded bySrinivasa Rao G
- r05320403 Microwave Engineeringuploaded bySrinivasa Rao G
- 41 Mca Nr Software Engineeringuploaded bySrinivasa Rao G
- 41 Mca or Software Engineeringuploaded bySrinivasa Rao G
- r6 43 Mca Data Warehousing and Mining Set1uploaded bySrinivasa Rao G
- r5 402 Mba Management of Technology Set1uploaded bySrinivasa Rao G
- 41 Mca Nr Software Engineeringuploaded bySrinivasa Rao G
- r5 401 Mba Strategic Management Set1uploaded bySrinivasa Rao G
- r05320205 Switchgear and Protectionuploaded bySrinivasa Rao G
- r05320305 Design of Machine Members IIuploaded bySrinivasa Rao G
- Rr322305 Immunologyuploaded bySrinivasa Rao G
- r5 401 Mba Strategic Management Set1uploaded bySrinivasa Rao G
- 43-Mca-Or-Design and Analysis of Algorithmuploaded bySrinivasa Rao G
- r6 48 Mca Mobile Computing Set1uploaded bySrinivasa Rao G
- r6 33 Mca Unix Networks Programming Set1uploaded bySrinivasa Rao G
- r6 34 Mca Management Information Systems Set1uploaded bySrinivasa Rao G
- r6 43 Mca Data Warehousing and Mining Set1uploaded bySrinivasa Rao G
- r6 47 Mca Distributed Operating Systems Set1uploaded bySrinivasa Rao G
- Nr-35-Mca-Design and Analysis of Algorithmuploaded bySrinivasa Rao G
- Or 32 Mcacomputer Communication Networksuploaded bySrinivasa Rao G
- r5 304 Mba Enterprise Resource Planninguploaded bySrinivasa Rao G
- r5 305 Mba Retailing Management Set1uploaded bySrinivasa Rao G
- Or 34 Mca Management Information Systemsuploaded bySrinivasa Rao G
- Nr 31 Mca Database Management Systemsuploaded bySrinivasa Rao G
- Nr 302 Mba Cost and Management Accounting Set1uploaded bySrinivasa Rao G
- r5 410 Mba Management of Change Set1uploaded bySrinivasa Rao G
- Nr 305 Mba Retailing Management Set1uploaded bySrinivasa Rao G
- r5 408 Mba Decision Support Systems Set1uploaded bySrinivasa Rao G

Close Dialog## Are you sure?

This action might not be possible to undo. Are you sure you want to continue?

Loading