Which are binary search trees

Assignment Help Computer Engineering
Reference no: EM132117111

QUESTION 1

If both of the child references of a binary tree node are non-null, it follows that the node must be ____.

a root node

a leaf node

a child node

an interior node

QUESTION 2

Which of the following statements about binary trees is correct?

Each node in a binary tree has at least two child nodes.

Each node in a binary tree has at most two child nodes.

The number of child nodes for each node in a binary tree is any power of two.

If divided down the middle from top to bottom, a binary tree must be symmetrical.

QUESTION 3

Consider the following tree diagram:

Which of the following nodes are leaf nodes?

C

B

H

B and H

QUESTION 4

Consider the following tree diagram:

Which of the following nodes are parent nodes?

C

C and R

R and D

C, R, and D

QUESTION 5

Consider the following binary search tree diagram:

Which of the following trees represents the correct result after inserting element T?

I

II

III

IV

QUESTION 6

Consider the following tree diagram:

What is the height of this tree?

3

4

5

7

QUESTION 7

What does the left node reference of a newly inserted binary search tree node get set to?

depends where the node is inserted

it gets set to the left child of the new node, if one exists

always null

it gets set to the left child of the root, if it exists

QUESTION 8

What are the differences between preorder, postorder, and inorder traversals?

The order in which we visit the left and right subtrees

Preorder only visits the left subtree

Postorder only visits the right subtree

The order of the root visit

QUESTION 9

Consider the following tree diagrams:

Which of the above are binary search trees?

I

II

I and II

Neither I nor II

QUESTION 10

Consider the following tree diagram:

What is the height of this tree?

3

4

6

7

QUESTION 11

Consider the following tree diagram:

Which of the following statements is NOT correct?

Nodes D and K form a subtree

Nodes H, M, and X form a subtree

Nodes R and N form a subtree

Nodes L and T form a subtree

QUESTION 12

Consider the following tree diagrams:

Which are binary search trees?

I

II

I and II

Neither I nor II

QUESTION 13

Consider the following binary search tree diagram:

Which nodes will be visited in order to insert the letter B into this tree?

H

H and D

H, D, and F

H, D, and A

QUESTION 14

If the child references of a binary tree node are both null, the node is ____.

a root node

a leaf node

a parent node

an interior node

QUESTION 15

Consider the following tree diagrams:

Which of these trees is considered to be balanced?

I

I and II

II and III

I and III

QUESTION 16

Consider the following tree diagrams:

Which of these trees is considered to be unbalanced?

I

II

III

II and III

QUESTION 17

Consider the following tree diagrams:

Which of the above are binary trees?

I

II

I and II

Neither I nor II

QUESTION 18

Consider the following tree diagram:

Which of the following statements is NOT correct?

R is an ancestor of N

C is an ancestor of N

D is an ancestor of P

H is an ancestor of M

QUESTION 19

Consider the following tree diagram:

Which of the following nodes are siblings?

D and U

H and M

D and B

L and T

QUESTION 20

Which action(s) will invalidate a min-heap so that, it may no longer have the properties of a min-heap?

I change the value of the root node

II remove the lowest level, right-most node

III remove the lowest level, left-most node

III

I and II

II and III

I and III

Reference no: EM132117111

Questions Cloud

How much are his monthly payments expected to be : William just graduated Indiana University but had to take out a $50,000 student loan. His loan requires him to make monthly payments over a 10-year period at 4.
How much must you invest in your account today : How much must you invest in your account today if you want to pay yourself $230 at the end of each of the next 15 years?
How much will you have saved : If instead of investing in the account, you saved your money in your cookie jar. How much will you have saved?
Annual management fee : You manage a hedge fund with $400 million in assets. Your fee structure provides for a 1% annual management fee with a 20% incentive
Which are binary search trees : Consider the following tree diagram: Which of the following statements is NOT correct?Which of these trees is considered to be balanced?
What is the operating cash flow : That is, the depreciation each year will be $128190/14. Assuming a tax rate of 26%, what is the operating cash flow?
Compensating balance versus discount loan : Weathers Catering Supply, Inc., needs to borrow $150,000 for 6 months. State Bank has offered to lend the funds at a 9% annual rate
What is the project npv if the tax rate : The annual operating cash flow is $70132 and the cost of capital is 5% What is the project's NPV if the tax rate is 30%?
How innovation has affected organisations management : Discuss the major sub-types of your innovation or the area of this innovation you are going to focus on (eg mobile commerce within technological innovation

Reviews

Write a Review

Computer Engineering Questions & Answers

  Mathematics in computing

Binary search tree, and postorder and preorder traversal Determine the shortest path in Graph

  Ict governance

ICT is defined as the term of Information and communication technologies, it is diverse set of technical tools and resources used by the government agencies to communicate and produce, circulate, store, and manage all information.

  Implementation of memory management

Assignment covers the following eight topics and explore the implementation of memory management, processes and threads.

  Realize business and organizational data storage

Realize business and organizational data storage and fast access times are much more important than they have ever been. Compare and contrast magnetic tapes, magnetic disks, optical discs

  What is the protocol overhead

What are the advantages of using a compiled language over an interpreted one? Under what circumstances would you select to use an interpreted language?

  Implementation of memory management

Paper describes about memory management. How memory is used in executing programs and its critical support for applications.

  Define open and closed loop control systems

Define open and closed loop cotrol systems.Explain difference between time varying and time invariant control system wth suitable example.

  Prepare a proposal to deploy windows server

Prepare a proposal to deploy Windows Server onto an existing network based on the provided scenario.

  Security policy document project

Analyze security requirements and develop a security policy

  Write a procedure that produces independent stack objects

Write a procedure (make-stack) that produces independent stack objects, using a message-passing style, e.g.

  Define a suitable functional unit

Define a suitable functional unit for a comparative study between two different types of paint.

  Calculate yield to maturity and bond prices

Calculate yield to maturity (YTM) and bond prices

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd