# Mathematics/Mathematics MCQs Set-4 Sample Test,Sample questions

## Question: ``` If a Graph Structured Stack contains {1,2,3,4} {1,5,3,4} {1,6,7,4} and {8,9,7,4}, what would be the source and sink vertices of the DAC? ```

1.Source – 1, 8 Sink – 7,4

2.Source – 1 Sink – 8,4

3.Source – 1, 8 Sink – 4

4.Source – 4, Sink – 1,8

1.15

2.3

3.1

4.11

## Question: ```A Graph Structured Stack is a _____________ ```

1.Undirected Graph

2.Directed Graph

3.Directed Acyclic Graph

4.Regular Graph

## Question: ```A man wants to go different places in the world. He has listed them down all. But there are some places where he wants to visit before some other places. What application of graph can he use to determine that? ```

1.Depth First Search

3.Topological Sorting

4.Dijkstra’s Shortest path algorithm

## Question: ```And Inverter Graph is a type of __________ ```

1.Multigraph

2.Cyclic Graph

3.Directed Acyclic Graph

4.Directed Acyclic Word Graph

## Question: ```Binary Decision Diagram is a type of __________ ```

1.Multigraph

2.Cyclic Graph

3.Directed Acyclic Graph

4.Directed Acyclic Word Graph

## Question: ```Can a tree stored in an array using either one of inorder or post order or pre order traversals be again reformed? ```

1.Yes just traverse through the array and form the tree

2.No we need one more traversal to form a tree

3.No in case of sparse trees

4.Yes by using both inorder and array elements

## Question: ```Consider a situation of writing a binary tree into a file with memory storage efficiency in mind, is array representation of tree is good? ```

1.yes because we are overcoming the need of pointers and so space efficiency

2.yes because array values are indexable

3.No it is not efficient in case of sparse trees and remaning cases it is fine

4.No linked list representation of tree is only fine

1.001111

2.101111

3.101110

4.001110

## Question: ```Given an array of element 5, 7, 9, 1, 3, 10, 8, 4. Which of the following are the correct sequences of elements after inserting all the elements in a min-heap? ```

1.1,3,4,5,7,8,9,10

2.1,4,3,9,8,5,7,10

3.1,3,4,5,8,7,9,10

4.1,3,7,4,8,5,9,10

## Question: ```Graph Structured Stack finds its application in _____________ ```

1.Bogo Sort

2.Tomita’s Algorithm

3.Todd–Coxeter algorithm

4.Heap Sort

## Question: ```How many children does a binary tree have? ```

1.2

2.any number of children

3.0 or 1 or 2

4.0 or 1

1.one

2.two

3.three

4.four

## Question: ```If a connected Graph (G) contains n vertices what would be the rank of its incidence matrix? ```

1.n-1

2.values greater than n are possible

3.values less than n-1 are possible

4.insufficient Information is given

1.(n*n-n-2*m)/2

2.(n*n+n+2*m)/2

3.(n*n-n-2*m)/2

4.(n*n-n+2*m)/2

## Question: ```If the tree is not a complete binary tree then what changes can be made for easy access of children of a node in the array? ```

1.every node stores data saying which of its children exist in the array

2.no need of any changes continue with 2w and 2w+1, if node is at i

3.keep a seperate table telling children of a node

4.use another array parallel to the array with tree

1.1

2.2

3.3

4.4

1.dashed, bold

2.bold, dashed

3.dotted, bold

4.dotted, dashed

1.Maximum Degree

2.Minimum Degree

3.Any degree

4.Zero Degree

## Question: ```In which of the following case does a Binary Decision Diagram is used for? ```

1.Representation of Boolean Functions

2.String Matching

3.Searching

4.Sorting of number

1.O(V + E)

2.O(V)

3.O(E)

4.O(V*E)

## Question: ```Size of an And Inverter Graph is the number of _______ gates and the number of logic levels is number of ________ gates on the __________ path from a primary input to a primary output. ```

1.AND, AND, average

2.AND, OR, longest

3.OR, OR, shortest

4.AND, AND, longest

## Question: ```The column sum in an incidence matrix for a directed graph having no self loop is __________ ```

1.0

2.1

3.2

4.equal to the number of edges

## Question: ```The column sum in an incidence matrix for a simple graph is __________ ```

1.depends on number of edges

2.always greater than 2

3.equal to 2

4.equal to the number of edges

1.O(V*V)

2.O(V+E)

3.O(1)

4.O(E)

## Question: ```Topological sort can be applied to which of the following graphs? ```

1.Undirected Cyclic Graphs

2.Directed Cyclic Graphs

3.Undirected Acyclic Graphs

4.Directed Acyclic Graphs

## Question: ```Topological sort can be implemented by? ```

1.Using Depth First Search

3.Using Depth and Breadth First Search

4.Using level ordered search

## Question: ```Topological sort is equivalent to which of the traversals in trees? ```

1.Pre-order traversal

2.Post-order traversal

3.In-order traversal

4.Level-order traversal

## Question: ```Topological sort of a Directed Acyclic graph is? ```

1.Always unique

2.Always Not unique

3.Sometimes unique and sometimes not unique

4.Always unique if graph has even number of vertices

## Question: ```What are the children for node ‘w’ of a complete-binary tree in an array representation? ```

1.2w and 2w+1

2.2+w and 2-w

3.w+1/2 and w/2

4.w-1/2 and w+1/2

## Question: ```What are the dimensions of an incidence matrix? ```

1.Number of edges*number of edges

2.Number of edges*number of vertices

3.Number of vertices*number of vertices

4.Number of edges * (1⁄2 * number of vertices)

## Question: ```What are the set of functions that are to be executed to get the following output? cat ```

1.push(c, s); push(a, s); push(t, s); pop(s); pop(s); pop(s);

2.push(c,s); pop(s); push(a,s); pop(s);push(t,s);pop(s);

3.pop(c ); pop(a); pop(t);

4.push(c,s); push(a,s); pop(t);

## Question: ```What is the location of a parent node for any arbitary node i? ```

1.(i/2) position

2.(i+1)/ position

3.floor(i/2) position

4.ceil(i/2) position

## Question: ```What is the number of edges present in a complete graph having n vertices? ```

1.(n*(n+1))/2

2.(n*(n-1))/2

3.n

4.Information given is insufficient

1.floor(w-1/2)

2.ceil(w-1/2)

3.w-1/2

4.w/2

## Question: ```What is/are the disadvantages of implementing tree using normal arrays? ```

1.difficulty in knowing children nodes of a node

2.difficult in finding the parent of a node

3.have to know the maximum number of nodes possible before creation of trees

4.difficult to implement

1.bbabbca

2.abbcabb

3.bbacbba

4.bbacabb

## Question: ```When the topological sort of a graph is unique? ```

1.When there exists a hamiltonian path in the graph

2.In the presence of multiple nodes with indegree 0

3.In the presence of single node with indegree 0

4.In the presence of single node with outdegree 0

1.queue

2.stack

3.tree

4.graph

## Question: ```Which is the predefined method available in Java to convert decimal to binary numbers? ```

1.toBinaryInteger(int)

2.toBinaryValue(int)

3.toBinaryNumber(int)

4.toBinaryString(int)

## Question: ```Which of the following is not an application of topological sorting? ```

2.Finding Deadlock in an Operating System

3.Finding Cycle in a graph

4.Ordered Statistics

## Question: ```Which of the following logical operation can’t be implemented by polynomial time graph manipulation algorithms using Binary Decision Diagrams? ```

1.Conjunction

2.Disjunction

3.Negation

4.Tautology Checking

## Question: ```Which of the following properties does a simple graph not hold? ```

1.Must be connected

2.Must be unweighted

3.Must have no loops or multiple edges

4.Must have no multiple edges

## Question: ```Which of the following statements for a simple graph is correct? ```

1.Every path is a trail

2.Every trail is a path

3.Every trail is a path as well as every path is a trail

4.Path and trail have no relation

## More MCQS

##### R4R Team
R4Rin Top Tutorials are Core Java,Hibernate ,Spring,Sturts.The content on R4R.in website is done by expert team not only with the help of books but along with the strong professional knowledge in all context like coding,designing, marketing,etc!