Escrito por estudiantes que aprobaron Inmediatamente disponible después del pago Leer en línea o como PDF ¿Documento equivocado? Cámbialo gratis 4,6 TrustPilot
logo-home
Document preview thumbnail
Vista previa 3 fuera de 16 páginas
Examen

WGU D278 OA EXAM SCRIPTING AND PROGRAMMING FOUNDATIONS 2026 PRACTICE SCRIPT QUESTIONS ANSWERS INCLUDED

Document preview thumbnail
Vista previa 3 fuera de 16 páginas

WGU D278 OA EXAM SCRIPTING AND PROGRAMMING FOUNDATIONS 2026 PRACTICE SCRIPT QUESTIONS ANSWERS INCLUDED

Vista previa del contenido

WGU D278 OA EXAM SCRIPTING AND
PROGRAMMING FOUNDATIONS 2026
PRACTICE SCRIPT QUESTIONS ANSWERS
INCLUDED
◉ What happens if you define a function but do not call it? Answer:
Nothing. The code will simply remain in memory but will not execute.


◉ A function, anyKey, has an input x and an output z. What does
anyKey return? Answer: z


◉ function popcorn(integer k) returns integer y y = k * 2 What does
popcorn(12) evaluate to? Answer: 24


◉ function math(integer x) returns integer y y = 3 * x + 1 What does
math(5) evaluate to? Answer: 16


◉ Function hello() Put "Hello my friend" to output What output appears
after two successive calls to the function? Answer: Hello my friendHello
my friend


◉ Using the following function, which portion is the function
declaration? function myFunction(integer b) a = b - 3 returns integer a +
b myFunction(6) Answer: function myFunction(integer b)

,◉ Using the following function, which portion contains the function's
argument? function myFunction(integer b) a = b - 3 returns integer a + b
myFunction(6) Answer: myFunction(6)


◉ Using the following function, which portion calls the function?
function myFunction(integer b) a = b - 3 returns integer a + b
myFunction(6) Answer: myFunction(6)


◉ Using the following function, which portion defines the output?
function myFunction(integer b) a = b - 3 returns integer a + b
myFunction(6) Answer: returns integer a + b


◉ Your user needs to enter a number into the program that will be used
throughout its execution. Before the user enters a number, which loop
type can determine how many times the loop will run? Answer: for


◉ Which loop types are best suited to continually check a test
expression? Answer: while
do while


◉ What type of loop is best suited to perform operations over a range of
values? Answer: for


◉ What type of loop is shown here? Answer: while

, ◉ What is the purpose of an "if" statement? Answer: To control what
code executes based on the result of a test expression.


◉ What is it called if a "while" statement's test expression never changes
to false? Answer: Infinite Loop


◉ How many times can you call a function to run? Answer: as many
times as you want.


◉ What is the primary difference between a "while" loop and a "do
while" loop? Answer: The "do while" is guarenteed to run at least once
before testing the condition.


◉ How many times will this loop iterate? for i = 0; i < 4; i = i + 1; //
Loop statements Answer: four times


◉ Fill in the blank so that the loop will iterate 10 times. for i = 1;
_________; i = i + 1; // Loop statements Answer: i <= 10


◉ What is put to output by the following pseudocode? x = 4 while x >=
0 Put x to output x = x - 2 Answer: 420

Información del documento

Subido en
27 de marzo de 2026
Número de páginas
16
Escrito en
2025/2026
Tipo
Examen
Contiene
Preguntas y respuestas
$12.99

¿Documento equivocado? Cámbialo gratis Dentro de los 14 días posteriores a la compra y antes de descargarlo, puedes elegir otro documento. Puedes gastar el importe de nuevo.
Escrito por estudiantes que aprobaron
Inmediatamente disponible después del pago
Leer en línea o como PDF

Seller avatar
Los indicadores de reputación están sujetos a la cantidad de artículos vendidos por una tarifa y las reseñas que ha recibido por esos documentos. Hay tres niveles: Bronce, Plata y Oro. Cuanto mayor reputación, más podrás confiar en la calidad del trabajo del vendedor.
FocusFile7
3.8
(22)
Vendido
218
Seguidores
3
Artículos
54806
Última venta
15 horas hace


Por qué los estudiantes eligen Stuvia

Creado por compañeros estudiantes, verificado por reseñas

Calidad en la que puedes confiar: escrito por estudiantes que aprobaron y evaluado por otros que han usado estos resúmenes.

¿No estás satisfecho? Elige otro documento

¡No te preocupes! Puedes elegir directamente otro documento que se ajuste mejor a lo que buscas.

Paga como quieras, empieza a estudiar al instante

Sin suscripción, sin compromisos. Paga como estés acostumbrado con tarjeta de crédito y descarga tu documento PDF inmediatamente.

Student with book image

“Comprado, descargado y aprobado. Así de fácil puede ser.”

Alisha Student

Preguntas frecuentes