Page 1 of 398
WGU C960: DISCRETE MATHEMATICS II | PRE-
ASSESSMENT (GFO1) (PGFO) | {LATEST 2026/
2027 UPDATE} COMPLETE ACTUAL AND
AUTHENTIC EXAM | BRAND NEW!
1.3.1: Algorithm to compute the smallest of three numbers.
Input: a = 7, b = 5, c =9
min := a
If ( b < min ), min := b
If ( c < min ), min := c
Return ( min )
What's min?
5
1.4.2: If-else-statement.
x := 3
y := 6
If ( x < y )
min := x
,Page 2 of 398
max := y
Else
min := y
max := x
End-if
What is min & max?
min = 3, max = 6
1.4.2: If-else-statement.
x = :7
y =: 2
If ( x < y )
min := x
max := y
Else
min := y
max := x
End-if
What is min & max?
min = 2, max = 7
,Page 3 of 398
Lesson 1.4.3
What is the value of abs after the following lines of code are run?
x := 2
If ( x > 0 )
abs := x
Else
abs := -x
End-if
2
The condition ( x > 0 ) evaluates to true because the value of x is 2. The
line abs := x is executed and the line abs := -x is skipped. Therefore the
final value of abs is 2.
Lesson 1.4.3
What is the value of abs after the following lines of code are run?
x := -2
If ( x > 0 )
abs := x
Else
, Page 4 of 398
abs := -x
End-if
2
The condition ( x > 0 ) evaluates to false because the value of x is -2.
The line abs := x is skipped and the line abs := -x is executed. Therefore
the final value of abs is -x, which is -(-2) = 2.
1.5.2: For-loops.
What is the value of sum after the second iteration?
sum := 0
For i = 2 to 5
sum := sum + i
End-for
5
In the first iteration, i = 2. In the second iteration, i = 3. 2 + 3 = 5.
Lesson 1.5.2 For-loops
How many iterations will the for-loop execute?
sum := 0
For i = 2 to 5
WGU C960: DISCRETE MATHEMATICS II | PRE-
ASSESSMENT (GFO1) (PGFO) | {LATEST 2026/
2027 UPDATE} COMPLETE ACTUAL AND
AUTHENTIC EXAM | BRAND NEW!
1.3.1: Algorithm to compute the smallest of three numbers.
Input: a = 7, b = 5, c =9
min := a
If ( b < min ), min := b
If ( c < min ), min := c
Return ( min )
What's min?
5
1.4.2: If-else-statement.
x := 3
y := 6
If ( x < y )
min := x
,Page 2 of 398
max := y
Else
min := y
max := x
End-if
What is min & max?
min = 3, max = 6
1.4.2: If-else-statement.
x = :7
y =: 2
If ( x < y )
min := x
max := y
Else
min := y
max := x
End-if
What is min & max?
min = 2, max = 7
,Page 3 of 398
Lesson 1.4.3
What is the value of abs after the following lines of code are run?
x := 2
If ( x > 0 )
abs := x
Else
abs := -x
End-if
2
The condition ( x > 0 ) evaluates to true because the value of x is 2. The
line abs := x is executed and the line abs := -x is skipped. Therefore the
final value of abs is 2.
Lesson 1.4.3
What is the value of abs after the following lines of code are run?
x := -2
If ( x > 0 )
abs := x
Else
, Page 4 of 398
abs := -x
End-if
2
The condition ( x > 0 ) evaluates to false because the value of x is -2.
The line abs := x is skipped and the line abs := -x is executed. Therefore
the final value of abs is -x, which is -(-2) = 2.
1.5.2: For-loops.
What is the value of sum after the second iteration?
sum := 0
For i = 2 to 5
sum := sum + i
End-for
5
In the first iteration, i = 2. In the second iteration, i = 3. 2 + 3 = 5.
Lesson 1.5.2 For-loops
How many iterations will the for-loop execute?
sum := 0
For i = 2 to 5