5. A full binary tree with n leaves contains [A] n nodes. [B] log n 2 nodes. [C] 2n 1 nodes. [D] n 2 nodes.



Similar documents
DATA STRUCTURES USING C

1. The memory address of the first element of an array is called A. floor address B. foundation addressc. first address D.

Krishna Institute of Engineering & Technology, Ghaziabad Department of Computer Application MCA-213 : DATA STRUCTURES USING C

Data Structure [Question Bank]

10CS35: Data Structures Using C

PES Institute of Technology-BSC QUESTION BANK

1) The postfix expression for the infix expression A+B*(C+D)/F+D*E is ABCD+*F/DE*++

Questions 1 through 25 are worth 2 points each. Choose one best answer for each.

CSE 326, Data Structures. Sample Final Exam. Problem Max Points Score 1 14 (2x7) 2 18 (3x6) Total 92.

MAX = 5 Current = 0 'This will declare an array with 5 elements. Inserting a Value onto the Stack (Push)

Binary Search Trees CMPSC 122

Home Page. Data Structures. Title Page. Page 1 of 24. Go Back. Full Screen. Close. Quit

Linked Lists, Stacks, Queues, Deques. It s time for a chainge!

Atmiya Infotech Pvt. Ltd. Data Structure. By Ajay Raiyani. Yogidham, Kalawad Road, Rajkot. Ph : ,

Data Structures Fibonacci Heaps, Amortized Analysis

Analysis of a Search Algorithm

GCE Computing. COMP3 Problem Solving, Programming, Operating Systems, Databases and Networking Report on the Examination.

INTERNATIONAL JOURNAL OF PURE AND APPLIED RESEARCH IN ENGINEERING AND TECHNOLOGY

Converting a Number from Decimal to Binary

Data Structures Using C++ 2E. Chapter 5 Linked Lists

Binary Search Trees. Data in each node. Larger than the data in its left child Smaller than the data in its right child

1. Relational database accesses data in a sequential form. (Figures 7.1, 7.2)

Previous Lectures. B-Trees. External storage. Two types of memory. B-trees. Main principles

Abstract Data Type. EECS 281: Data Structures and Algorithms. The Foundation: Data Structures and Abstract Data Types

TREE BASIC TERMINOLOGIES

GUJARAT TECHNOLOGICAL UNIVERSITY, AHMEDABAD, GUJARAT. Course Curriculum. DATA STRUCTURES (Code: )

root node level: internal node edge leaf node Data Structures & Algorithms McQuain

Unit Write iterative and recursive C functions to find the greatest common divisor of two integers. [6]

Algorithms and Data Structures

Unordered Linked Lists

Data Structures. Level 6 C Module Descriptor

Data Structures and Data Manipulation

5. Binary objects labeling

AP Computer Science AB Syllabus 1

Data Structures. Chapter 8

Load balancing Static Load Balancing

2) What is the structure of an organization? Explain how IT support at different organizational levels.

Sorting revisited. Build the binary search tree: O(n^2) Traverse the binary tree: O(n) Total: O(n^2) + O(n) = O(n^2)

Social Media Mining. Graph Essentials

Java Software Structures

B-Trees. Algorithms and data structures for external memory as opposed to the main memory B-Trees. B -trees

Binary Search Trees. A Generic Tree. Binary Trees. Nodes in a binary search tree ( B-S-T) are of the form. P parent. Key. Satellite data L R

International Journal of Software and Web Sciences (IJSWS)

2. (a) Explain the strassen s matrix multiplication. (b) Write deletion algorithm, of Binary search tree. [8+8]

V. Adamchik 1. Graph Theory. Victor Adamchik. Fall of 2005

Data Structure and Algorithm I Midterm Examination 120 points Time: 9:10am-12:10pm (180 minutes), Friday, November 12, 2010

Data Structures Using C++

Quiz 4 Solutions EECS 211: FUNDAMENTALS OF COMPUTER PROGRAMMING II. 1 Q u i z 4 S o l u t i o n s

Data Structure with C

Matrix Multiplication

Ordered Lists and Binary Trees

Chapter 8: Structures for Files. Truong Quynh Chi Spring- 2013

COMPUTER SCIENCE. Paper 1 (THEORY)

Load Balancing and Termination Detection

Module 2 Stacks and Queues: Abstract Data Types

Binary Heaps * * * * * * * / / \ / \ / \ / \ / \ * * * * * * * * * * * / / \ / \ / / \ / \ * * * * * * * * * *

Binary Heap Algorithms

Data Structures, Practice Homework 3, with Solutions (not to be handed in)

EE602 Algorithms GEOMETRIC INTERSECTION CHAPTER 27

Exam study sheet for CS2711. List of topics

Lecture 6: Binary Search Trees CSCI Algorithms I. Andrew Rosenberg

Scan-Line Fill. Scan-Line Algorithm. Sort by scan line Fill each span vertex order generated by vertex list

Symbol Tables. Introduction

Any two nodes which are connected by an edge in a graph are called adjacent node.

The Union-Find Problem Kruskal s algorithm for finding an MST presented us with a problem in data-structure design. As we looked at each edge,

Eastern Washington University Department of Computer Science. Questionnaire for Prospective Masters in Computer Science Students

G. H. RAISONI COLLEGE OF ENGG NAGPUR-16 Session DEPARTMENT CSE Semester IV SUBJECT DSPD

2) Write in detail the issues in the design of code generator.

Parallelization: Binary Tree Traversal

Data Structures and Algorithms

Memory Allocation. Static Allocation. Dynamic Allocation. Memory Management. Dynamic Allocation. Dynamic Storage Allocation

Copyright 2007 Ramez Elmasri and Shamkant B. Navathe. Slide 13-1

Data Structures UNIT III. Model Question Answer

Why? A central concept in Computer Science. Algorithms are ubiquitous.

BSc (Hons) Business Information Systems, BSc (Hons) Computer Science with Network Security. & BSc. (Hons.) Software Engineering

Chapter 13 Disk Storage, Basic File Structures, and Hashing.

DATA STRUCTURE - QUEUE

Load Balancing and Termination Detection

Chapter 13. Disk Storage, Basic File Structures, and Hashing

Chapter 6: Physical Database Design and Performance. Database Development Process. Physical Design Process. Physical Database Design

Chapter 3: Restricted Structures Page 1

Introduction to Data Structures and Algorithms

Sample Questions Csci 1112 A. Bellaachia

SCAN: A Structural Clustering Algorithm for Networks

A binary heap is a complete binary tree, where each node has a higher priority than its children. This is called heap-order property

Graph Theory Problems and Solutions

Load Balancing and Termination Detection

Application of Stacks: Postfix Expressions Calculator (cont d.)

Physical Data Organization

Eastern Washington University Department of Computer Science. Questionnaire for Prospective Masters in Computer Science Students

A binary search tree or BST is a binary tree that is either empty or in which the data element of each node has a key, and:

Lecture 12 Doubly Linked Lists (with Recursion)

Efficient Data Structures for Decision Diagrams

Algorithms Chapter 12 Binary Search Trees

A TOOL FOR DATA STRUCTURE VISUALIZATION AND USER-DEFINED ALGORITHM ANIMATION

7.1 Our Current Model

Linked List as an ADT (cont d.)

Sequential Data Structures

Persistent Binary Search Trees

Analysis of Algorithms I: Binary Search Trees

Transcription:

1. The advantage of.. is that they solve the problem if sequential storage representation. But disadvantage in that is they are sequential lists. [A] Lists [B] Linked Lists [A] Trees [A] Queues 2. The worst case occur in linear search algorithm when [A] Item is somewhere in the middle of the array [B] Item is not in the array at all [C] Item is the last element in the array [D] Item is the last element in the array or item is not there at all 3. Linked lists are best suited [A] for relatively permanent collections of data [B] for the size of the structure and the data in the structure are constantly changing [C] for both of above situation [D] for none of above situation 4. he elements of an array are stored successively in memory cells because [A] by this way computer can keep track only the address of the first element and the addresses of other elements can be calculated [B] the architecture of computer memory does not allow arrays to store other than serially [C] both of above [D] none of above 5. A full binary tree with n leaves contains [A] n nodes. [B] log n 2 nodes. [C] 2n 1 nodes. [D] n 2 nodes. 6. A vertex of degree one is called [A] ppadent [B] Isolated vertex [C] Null vertex [D] Colored vertex

7. The in-order traversal of tree will yield a sorted listing of elements of tree in [A] binary trees [B] binary search trees [C] heaps [D] binary heaps 8. Finding the location of the element with a given value is: [A] Traversal [B] Search [C] Sort [D] None of above 9. A graph with n vertices will definitely have a parallel edge or self loop of the total number of edges are [A] more than n [B] more than n+1 [C] more than (n+1)/2 [D] more than n(n-1)/2 10. Which of the following is useful in implementing quick sort? [A] Stack [B] Set [C] List [D] Queue 11. A sorting algorithm which can prove to be a best time algorithm in one case and a worst time algorithm at other time? [A] Selection Sort [B] Heap Sort [C] Quick Sortno [D] All of the above 12. Which of the following can be used as a criterion for classification of data structures used in language processing?. [A] nature of a data structure [B] lifetime of a data structure [C] purpose of a data structure [D] All of the above

13. Sparse matrices have? [A] no zero. [B] many zero. [C] higher dimenstion. [D] none. 14. The postfix form of the expression (A+ B)*(C*D- E)*F / G is? [A] AB+ CD*E - FG /** [B] AB + CD* E - F **G / [C] AB + CD* E - *F *G / [D] AB + CDE * - * F *G / 15. The data structure required to check whether an expression contains balanced parenthesis is? [A] Stack [B] Queue [C] Array [D] Tree 16. The Worst case occur in linear search algorithm when [A] Item is somewhere in the middle of the array [B] Item is not in the array at all [C] Item is the last element in the array [D] Item is the last element in the array or is not there at all 17. Consider the linked list implementation of a stack. Which of the following node is considered as Top of the stack? [A] First node [B] Last node [C] Any node [D] Middle node 18. If every node u in G is adjacent to every other node v in G, A graph is said to be [A] isolated [B] complete [C] finite [D] strongly connected

19. If the MAX_SIZE is the size of the array used in the implementation of circular queue. How is rear manipulated while inserting an element in the queue? [A] rear=(rear%1)+max_size [B] rear=rear%(max_size+1) [C] rear=(rear+1)%max_size [D] rear=rear+(1%max_size) 20. In linked list implementation of a queue, front and rear pointers are tracked. Which of these pointers will change during an insertion into EMPTY queue? [A] Only front pointer [B] Only rear pointer [C] Both front and rear pointer [D] None of these 21. A binary tree can easily be converted into q 2-tree [A] by replacing each empty sub tree by a new internal node [B] by inserting an internal nodes for non-empty node [C] by inserting an external nodes for non-empty node [D] by replacing each empty sub tree by a new external node 22. A graph is said to be if its edges are assigned data. [A] Tagged [B] Marked [C] Lebeled [D] Sticked 23. A binary tree whose every node has either zero or two children is called [A] Complete binary tree [B] Binary search tree [C] Extended binary tree [D] None of these 24. In the array implementation of circular queue, which of the following operation take worst case linear time? [A] Insertion [B] Deletion

[C] To empty a queue [D] None 25. The space factor when determining the efficiency of algorithm is measured by [A] Counting the maximum memory needed by the algorithm [B] Counting the minimum memory needed by the algorithm [C] Counting the average memory needed by the algorithm [D] Counting the maximum disk space needed by the algorithm ANSWERS 1 -- B 2 -- D 3 -- B 4 -- A 5 -- C 6 -- A 7 -- D 8 -- B 9 -- D 10 -- A 11 -- C 12 -- D 13 -- B 14 -- A 15 -- A 16 -- D 17 -- A 18 -- B 19 -- C 20 -- C 21 -- D 22 -- C 23 -- C 24 -- D 25 -- A If you have any concerns, please drop us an email(info@alljobinfo.com) Thanks in Advance