Wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Final Exam - IT 2 Discrete Math

Total questions: 50

Worksheet time: 47mins

Name
Class
Date
1.

______ is a discrete structure that represents hierarchical relationships between individual elements or nodes.

a)

Tree

b)

Root

c)

Graph

d)

Vertices

2.
The tree diagram shows the outcomes of rolling a die and flipping a coin.  
How many total outcomes are there?  
a)
6
b)
12
c)
24
d)
36
3.
Tree Diagram
a)
A written list of all possible outcomes
b)
A description of all possible outcomes
c)
A drawing with branches of all possible outcomes
4.

Jason can choose 1 pair of pants and one shirt to wear today. Here are his choices. Which tree diagram shows all of the combinations that Jason can choose from?

a)
b)
c)
d)
5.

Use the tree diagram to find the probability of spinning the same number in succession when the spinner is spun 2 times.

a)

1

b)

1/3

c)

1/4

d)

1/2

6.

A _____________ is a tree the vertices of which are assigned unique numbers from 1 to n.

a)

labeled tree

b)

unlabeled tree

c)

indirect tree

d)

direct tree

7.

An _____________ is a tree the vertices of which are not assigned any numbers.

a)

labeled tree

b)

unlabeled tree

c)

indirect tree

d)

direct tree

8.

A ____________ G is a connected acyclic graph with a special node that is called the root of the tree and every edge directly or indirectly originates from the root.

a)

rooted tree

b)

unlabled tree

c)

label tree

d)

graph

9.

_________ is a binary tree which satisfies the following property −


X in left sub-tree of vertex V,Value(X)≤Value(V)V,Value(X)≤Value(V)

Y in right sub-tree of vertex V,Value(Y)≥Value(V)

a)

Binary Search tree

b)

Linked list

c)

Heap

d)

None of the choices

10.
displays data items in a hierarchical view
a)
Flowchart
b)
Trees
c)
Binary Tree
d)
Binary Expression Tree
11.
A tree is composed of ____ connected by edges or lines.
a)
Fruit 
b)
Leaf Node
c)
Root Node
d)
Nodes
12.
A Balanced Tree has equal number of items on each subtree.
a)
True
b)
False
13.
A Kind of tree where every node in a tree can have at most two children.
a)
Binary Tree
b)
Binary Expression Tree
c)
Tree
d)
Binary Search Tree
14.
_____ is used to visit all the nodes of the tree in order.
a)
Height
b)
Edge
c)
Binary Tree Traversal
d)
Depth
15.
______ is invented by Donald Shell in 1959.
a)
Merge Sort
b)
Insertion Sort
c)
Shell Sort
d)
Quick Sort
16.
______ operates by partitioning an array into two subarrays and then calling itself to sort again these subarrays.
a)
Quick Sort
b)
Merge Sort
c)
Partitioning
d)
Shell Sort
17.
Root has more left descendants than the right descendants or vice versa.
a)
Balanced Tree
b)
Perfect Tree
c)
Right Tree
d)
Unbalanced Tree
18.

Contain a Loop or cycle is not a tree?

a)

True

b)

False

19.

A ___________ is a (not necessarily connected) simple un-directed graph with no simple circuits.

a)

forest

b)

tree

c)

node

d)

vertices

20.

An ________________ is graph, i.e., a set of objects (called vertices or nodes) that are connected together, where all the edges are bidirectional.

a)

undirected graph

b)

directed graph

c)

forest

d)

tree

21.

A ___________ is graph, i.e., a set of objects (called vertices or nodes) that are connected together, where all the edges are directed from one vertex to another.

a)

directed graph

b)

undirected graph

c)

tree

d)

forest

22.

A subtree of a tree T is a tree S consisting of a node in T and all of its descendants in T. The subtree corresponding to the root node is the entire tree; the subtreecorresponding to any other node is called a proper subtree.

a)

True

b)

False

23.

the height of the tree is ___________.

a)

3

b)

4

c)

5

d)

2

24.

Depth –The depth of a node is the number of edges from the node to the tree's root node.

a)

True

b)

False

25.

Height of node – The height of a node is the number of edges on the longest downward path between that node and a leaf.

a)

True

b)

False

26.

__________________: Every node has at most 2 children

a)

binary rooted tree

b)

complete binary rooted tree

c)

undefined binary rooted tree

d)

operation tree

27.

_________________: Every node has 0 or 2 children

a)

binary rooted tree

b)

complete binary rooted tree

c)

undefined binary rooted tree

d)

operation tree

28.
The graph below displays a relationship between 7 locations.  Can an Euler path be drawn for this graph?
a)
no, because there are exactly 2 vertices with an odd degree 
b)
no, because each vertex is of an even degree 
c)
yes, because there are exactly 2 vertices with an odd degree 
d)
yes, because each vertex is of an even degree 
29.

What is the cost using Nearest Neighbor Algorithm starting with vertex A?

a)

63

b)

58

c)

55

d)

52

30.
Use the nearest-neighbor algorithm to find a Hamilton Circuit starting at E. 
a)
E, A, C, D, B, E
b)
E, D, C, A, B, E
c)
E, D, C, B, A, E
d)
E, D, A, B, C, E
31.

An edge that begins and ends at the same vertex.

a)

Multiple edges

b)

Vertices

c)

Loop

d)

Node

32.

In the graph above, which of the following statements is true?

a)

A is adjacent to E

b)

A is not adjacent to D

c)

C is adjacent to D

d)

C is not adjacent to E

33.

In the graph shown, D is an example of a(n) ________ .

a)

Edge

b)

Vertex

c)

Path

d)

Sling

34.

In the graph shown, (A, F) is an example of a(n) ________ .

a)

Edge

b)

Vertex

c)

Path

d)

Sling

35.

Vertices are considered adjacent if ________ .

a)

An edge connects them

b)

There is a path from one vertex to the other

c)

Both vertices are contained in a cycle

d)

The length of the path between them is less than 5

36.
How many total votes are there in this election?
a)
35
b)
37
c)
40
d)
41
37.
Tracing all edges on a figure without picking up your pencil or repeating and starting and stopping at different spots
a)
Euler Circuit
b)
Euler Path
38.
Paths start and stop at
a)
same vertex
b)
different vertices
39.
Which of the following is false?
a)
Euler Paths exist when there are exactly two vertices of odd degree.
b)
Euler circuits exist when the degree of all vertices are even.
c)
A graph with more than two odd vertices will never have an Euler Path or Circuit.
d)
A graph with one odd vertex will have an Euler Path but not an Euler Circuit.
40.
This graph will have a Euler's Path. 
a)
True
b)
False
41.
What is the weight of edge AC?
a)
5
b)
6
c)
3
d)
11
42.

Which of the following is a cycle shown in the graph?

a)

B, F, A, B

b)

A, B, E

c)

A, E, D, A

d)

A, C, B, D, A

43.

Vertices are considered adjacent if ________ .

a)

An edge connects them

b)

There is a path from one vertex to the other

c)

Both vertices are contained in a cycle

d)

The length of the path between them is less than 5

44.

A complete graph is a graph _________ .

a)

where every vertex has a degree >= 1

b)

that has the maximum number of edges connecting vertices

c)

that for any two vertices, the graph has a path

d)

that has at least one edge to every vertex

45.

The number of edges needed in a complete graph with 5 vertices is ________ .

a)

10

b)

15

c)

5

d)

25

46.

What is the length of the path F, A, C, B, D?

a)

3

b)

4

c)

5

d)

6

47.

After completing Dijkstras algorithm to find the shortest path from A to G, we discover the cost of this path is ______ .

a)

4

b)

5

c)

6

d)

7

48.

Is the following graph connected?

a)

Yes

b)

No

49.

State whether you can find a Hamiltonian path, circuit or neither.

a)

Path

b)

Circuit

c)

Neither

50.

Using the following tournament information, construct a directed graph and find a ranking of the participants:

Between A and B, A wins

Between A and C, C wins

Between A and D, D wins

Between B and C, C wins

Between B and D, D wins

Between C and D, C wins

a)

1st place: A, 2nd place: B, 3rd place: C, 4th place: D

b)

1st place: B, 2nd place: A, 3rd place: D, 4th place: C

c)

1st place: C, 2nd place: D, 3rd place: A, 4th place: B

d)

1st place: D, 2nd place: C, 3rd place: B, 4th place: A