? Data Structure - 2130702 - Paper Solution for the GTU Exam Winter-2017 Home Subject Data Structure Database Management Systems About Us Contact Us Home Data Structure - 2130702 Winter - 2017 Paper Solution | Winter - 2017 Data Structure - 2130702 Date: 11/14/2017 Total Marks : 70 Q.1 (a) A two dimensional array is stored row by row, then what is the address of matrix element A[i,j] for n row and m column matrix? How array representation of polynomial 2x2+5xy+y2 can be done? 3 marks Answer (b) Which data structure is used in a time sharing single central processing unit and one main memory computer system where many users share the system simultaneously? How users are added for use of the system? 4 marks Answer (c) The Preorder traversal of the tree is: 7, 1, 0, 3, 2, 5, 4, 6, 9, 8, 10 The inorder traversal of the tree is : 01,2,3,4,5,6,7,8,9,10 What is the postorder traversal? How a general tree can be converted to binary tree? 7 marks Answer Q.2 (a) What is the problem with sign and magnitude representation if addition of +7 with -6 is performed? Evaluate 7+7 using 2’s complement representation and modulo 16 arithmetic. 3 marks Answer (b) Write an algorithm for calculating square of the number for all the prime numbers ranging between 1 to n. Perform time and space analysis. 4 marks Answer (c) Given a linked list whose typical node consists of an INFO and LINK field. Formulate an algorithm which will count the number of nodes in the list. 7 marks Answer OR (c) What is the need of doubly linked list? Consider a problem of inserting a node into a doubly linked linear list to the left of a specified node whose address is given by variable M. Give details of algorithm. 7 marks Answer Q.3 (a) How directed tree can be represented? 3 marks Answer (b) How following hash functions work? (i) The midsquare method (ii) Digit analysis 4 marks Answer (c) (i) In which case insertion and deletion cannot be performed in stack? (ii) How stack can be used to recognize strings aca,bcb,abcba,bacab,abbcbba? Show the trace of contents of stack for recognizing the string abcba. 7 marks Answer OR Q.3 (a) How primitive data type floating point is stored in computer? 3 marks Answer (b) A communications network is represented by graph. Each node represents a communication line and each edge indicate the presence of interconnection between the lines. Which traversal technique can be used to find breakdown in line? Explain. 4 marks Answer (c) (i) Convert a+b*c-d/e*h to postfix. (ii) Convert ((a+b^c^d)*(e+f/d)) to postfix. (iii)Which stack operations are needed for performing conversion from infix to postfix? Write the algorithm. 7 marks Answer Q.4 (a) How many null branches a binary tree possesses? 3 marks Answer (b) What is the difference between serial and sequential processing? How a record can be deleted in sequential file? 4 marks Answer (c) What is the advantage of circular queue? Write an algorithm for inserting ‘A’,’B’,’C’,delete ‘A’ and ‘B’and insert ‘D’ and ‘E’ in circular queue . 7 marks Answer OR Q.4 (a) Explain indexing structure for index files. 3 marks Answer (b) Write recursive algorithm for computing factorial. Which data structure can be used to implement this algorithm? 4 marks Answer (c) “If no interchanges occurred, then the table must be sorted and no further passes are required.” Which sorting method works on this principal? Apply above sorting technique on the following data 5 1 4 2 8 7 marks Answer Q.5 (a) How does priority queue work? 3 marks Answer (b) How binary search technique can be applied to search for a particular item with a certain key? 4 marks Answer (c) Apply quick sort on following data: 42 23 74 11 65 58 94 36 99 87 7 marks Answer OR Q.5 (a) Explain the structure of threaded binary tree. 3 marks Answer (b) How access of record is performed in multi key file organization? 4 marks Answer (c) Hash function map several keys into same address called collision. How collision resolution techniques work? 7 marks Answer Nail is still a very popular fashion replica handbags uk in autumn and gucci replica . The furry design on the hermes replica of the bag makes this autumn and handbags replica. Xiaobian likes the buckle like sapphire and looks quite replica handbags .