# Accenture Arrays, Linked Lists Trees and Graphs Quiz-1

Question 1

Time: 00:00:00
A binary search tree is generated by inserting in order the following integers:
50, 15, 62, 5, 20, 58, 91, 3, 8, 37, 60, 24

The number of the node in the left sub-tree and right sub-tree of the root, respectively, is

(3, 8)

(3, 8)

(8, 3)

(8, 3)

(7, 4)

(7, 4)

(4, 7)

(4, 7)

Once you attempt the question then PrepInsta explanation will be displayed.

Question 2

Time: 00:00:00
the run time for traversing all the nodes of a binary search tree with n nodes and printing them in an order is

a)
b)
c)
d)

O(n)

O(n)

O(√n)

O(√n)

O(log(n))

O(log(n))

O(nlg(n))

O(nlg(n))

Once you attempt the question then PrepInsta explanation will be displayed.

Question 3

Time: 00:00:00
Which type of traversal of binary search tree outputs the value in sorted order?

Post-order

Post-order

Pre-order

Pre-order

In-order

In-order

None

None

Once you attempt the question then PrepInsta explanation will be displayed.

Question 4

Time: 00:00:00
The height of a BST is given as h. Consider the height of the tree as the no. of edges in the longest path from root to the leaf. The maximum no. of nodes possible in the tree is?

2h-1 -1

2h-1 -1

2h+1 -1

2h+1 -1

2h +1

2h +1

2h-1 +1

2h-1 +1

Once you attempt the question then PrepInsta explanation will be displayed.

Question 5

Time: 00:00:00
Raman is 7 years old and he wants to colour a book. The book happens to be about DSA and contains 8 vertices in an undirected graph with 7 levels, he wants to use a different colour for every node. How many colors will he need?

63

63

63

63

28

28

32

32

Once you attempt the question then PrepInsta explanation will be displayed.

Question 6

Time: 00:00:00
What is Dynamic Allocation in Array?

Allocation that takes place at compile time

Allocation that takes place at compile time

Allocation that take place as bipartite graph

Allocation that take place as bipartite graph

memory allocation that takes place during run time rendering the resizing of an Array

memory allocation that takes place during run time rendering the resizing of an Array

All of these

All of these

Once you attempt the question then PrepInsta explanation will be displayed.

Question 7

Time: 00:00:00
Which of the following is true about bipartite Graph?

no cycle of odd length

no cycle of odd length

n^log n

n^log n

n edges

n edges

a cycle of odd length

a cycle of odd length

Once you attempt the question then PrepInsta explanation will be displayed.

Question 8

Time: 00:00:00
He again gets a book with x number of non-leaf nodes. How many total number of nodes will be there for hum color

2x

2x

x + 1

x + 1

Log x

Log x

2x + 1

2x + 1

Once you attempt the question then PrepInsta explanation will be displayed.

Question 9

Time: 00:00:00
Raman is 7 years old and he wants to color a book. The book happens to be about DSA and contains a Complete binary tree with 7 levels, he wants to use different color for every tree nodes. How many colors will he need?

28

28

31

31

63

63

127

127

Once you attempt the question then PrepInsta explanation will be displayed.

Question 10

Time: 00:00:00
In a Doubly Linked list how many nodes have atleast 1 node before and after it?

N+1

N+1

N

N

N-2

N-2

N-1

N-1

Once you attempt the question then PrepInsta explanation will be displayed.

["0","40","60","80","100"]
["Need more practice! \r\n \r\n \r\n","Keep trying! \r\n \r\n \r\n","Not bad! \r\n \r\n \r\n","Good work! \r\n \r\n \r\n","Perfect! \r\n \r\n \r\n"]

Personalized Analytics only Availble for Logged in users

Analytics below shows your performance in various Mocks on PrepInsta

Your average Analytics for this Quiz

Rank

-

Percentile

0%

Get over 200+ Courses under One Subscription

Don’t settle Learn from the Best with PrepInsta Prime Subscription

Learn from Top 1%

## One Subscription, For Everything

The new cool way of learning and upskilling -

Limitless Learning

One Subscription access everything

Job Assurance