WGU C173 EXAM 2025 | SCRIPTING AND PROGRAMMING EXAM | ALL
QUESTIONS AND CORRECT ANSWERS | ALREADY GRADED A+ | VERIFIED
ANSWERS | LATEST EXAM
Which operator should be used to deter-
%
mine if a number is evenly divisible by 5?
A car drove 200 miles using 10 gallons
of fuel. Which operation should be used
division
to compute the miles per gallon, which is
20?
A variable should hold a person's height
in meters. Which data type should the Float
variable be?
A variable should hold the names of all
past U.S. presidents. Which data type String array
should the variable be?
A program uses the number of seconds
in a minute in various calculations. How
Constant integer secondsPerMinute
should the item that holds the number of
seconds in a minute be declared?
A program determines if a user's age is
high enough to run for U.S. president.
The minimum age requirement is 35. Constant integer minAge
How should the item that holds the mini-
mum age be declared?
Given integer x = 3 and integer y = 5.
What is the value of the expression ( x / 6.5
2.0) + y?
Given float x = 10.2 and float y =
1.0.What is the value of the expression 10.2
x / y?
What kind of operator is the == in the
Equality
expression i == 20?
What is the purpose of parentheses () in
to group expressions
a programming expression?
Given float x = 3.0. Which expression
x / 2 + 0.5 /2 + .25
evaluates to 2.0?
, WGU C173 EXAM 2025 | SCRIPTING AND PROGRAMMING EXAM | ALL
QUESTIONS AND CORRECT ANSWERS | ALREADY GRADED A+ | VERIFIED
ANSWERS | LATEST EXAM
Which expression evaluates to true only
when the user is within 3 years of 21
( x >= 18) and ( x <= 24)
years, given a variable x containing a
user's age?
Which data type is used for items that are
Float
measured in length
Which data type should be used to
keep track of how many planes are in a Integer
hangar?
A function should convert hours and min-
utes to seconds, such as converting 1
Hours and minutes
hour and 10 minutes to 4,200 seconds.
What should be the input to the function?
A function returns a number x cubed. For
example, if x is 3, the function returns 3 *
x
3 * 3, or 27. What should be the input to
the function?
A function calculates the weight differ-
ence (Diff) given two sample weights (S1
Diff
and S2). What should be the output from
the function?
function P(integer x) returns integer y y =
10
2 * x What does P(5) evaluate to?
Function F() Put "Hey" to output What
entire output appears after three succes- HeyHeyHey
sive calls to F()?
What is a valid user-defined function
a valid identifier
name?
A function MyFct has an input x and an
z only
output z.What does MyFct return?
What is the return value of a function? Output of a function
QUESTIONS AND CORRECT ANSWERS | ALREADY GRADED A+ | VERIFIED
ANSWERS | LATEST EXAM
Which operator should be used to deter-
%
mine if a number is evenly divisible by 5?
A car drove 200 miles using 10 gallons
of fuel. Which operation should be used
division
to compute the miles per gallon, which is
20?
A variable should hold a person's height
in meters. Which data type should the Float
variable be?
A variable should hold the names of all
past U.S. presidents. Which data type String array
should the variable be?
A program uses the number of seconds
in a minute in various calculations. How
Constant integer secondsPerMinute
should the item that holds the number of
seconds in a minute be declared?
A program determines if a user's age is
high enough to run for U.S. president.
The minimum age requirement is 35. Constant integer minAge
How should the item that holds the mini-
mum age be declared?
Given integer x = 3 and integer y = 5.
What is the value of the expression ( x / 6.5
2.0) + y?
Given float x = 10.2 and float y =
1.0.What is the value of the expression 10.2
x / y?
What kind of operator is the == in the
Equality
expression i == 20?
What is the purpose of parentheses () in
to group expressions
a programming expression?
Given float x = 3.0. Which expression
x / 2 + 0.5 /2 + .25
evaluates to 2.0?
, WGU C173 EXAM 2025 | SCRIPTING AND PROGRAMMING EXAM | ALL
QUESTIONS AND CORRECT ANSWERS | ALREADY GRADED A+ | VERIFIED
ANSWERS | LATEST EXAM
Which expression evaluates to true only
when the user is within 3 years of 21
( x >= 18) and ( x <= 24)
years, given a variable x containing a
user's age?
Which data type is used for items that are
Float
measured in length
Which data type should be used to
keep track of how many planes are in a Integer
hangar?
A function should convert hours and min-
utes to seconds, such as converting 1
Hours and minutes
hour and 10 minutes to 4,200 seconds.
What should be the input to the function?
A function returns a number x cubed. For
example, if x is 3, the function returns 3 *
x
3 * 3, or 27. What should be the input to
the function?
A function calculates the weight differ-
ence (Diff) given two sample weights (S1
Diff
and S2). What should be the output from
the function?
function P(integer x) returns integer y y =
10
2 * x What does P(5) evaluate to?
Function F() Put "Hey" to output What
entire output appears after three succes- HeyHeyHey
sive calls to F()?
What is a valid user-defined function
a valid identifier
name?
A function MyFct has an input x and an
z only
output z.What does MyFct return?
What is the return value of a function? Output of a function