Month End Sale - 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: dm70dm

Scripting-and-Programming-Foundations WGU Scripting and Programming Foundations Exam Questions and Answers

Questions 4

What is the proper way to declare a student's grade point average throughout the term it this item is needed in several places in a program?

Options:

A.

variable int gpa

B.

constant float gpa

C.

constant int gpa

D.

variable float gpa

Buy Now
Questions 5

Review the following sequence diagram:

Scripting-and-Programming-Foundations Question 5

What does a sequence diagram do?

Options:

A.

Shows interactions awl indicates an order of events

B.

Shows interactions but does not specify an order of events

C.

Shows sialic elements of software

D.

Shows an order of events but does not specify all interactions

Buy Now
Questions 6

Consider the given function:

function K(string s1, string s2)

Put s1 to output

Put " and " to output

Put s2 to output

What is the total output when K("sign", "horse") is called 2 times?

Options:

A.

sign and horse and sign and horse

B.

sign and horsesign and horse

C.

sign and horse

D.

sign and horse

E.

sign and horse sign and horse

Buy Now
Questions 7

Which statement describes a compiled language?

Options:

A.

It runs one statement at a time by another program without the need for compilation.

B.

It is considered fairly safe because it forces the programmer to declare all variable types ahead of time and commit to those types during runtime.

C.

It can be run right away without converting the code into an executable file.

D.

It has code that is first converted to an executable file, and then run on a particular type of machine.

Buy Now
Questions 8

A software team has been commissioned to create an animation application. Which event takes place during the analysis phase in the agile approach?

Options:

A.

Sending the application to customers for additional evaluation after new features are added

B.

Deciding to add five new capabilities to the animation application based on customer feedback

C.

Writing the code for five new capabilities

D.

Deciding that new capabilities in the animation application will be written as functions without the needs of any new objects

Buy Now
Questions 9

Which type of language requires variables to be declared ahead of time and prohibits their types from changing while the program runs?

Options:

A.

Scripted (interpreted)

B.

Procedural

C.

Static

D.

Compiled

Buy Now
Questions 10

A sequence diagram is shown:

Scripting-and-Programming-Foundations Question 10

What is the purpose of a sequence diagram?

Options:

A.

It depicts program operations, branches, and loops.

B.

It outlines the needed computations.

C.

It illustrates the communication steps for a particular software scenario.

D.

It outlines the potential actions of a user

Buy Now
Questions 11

What is output by calling Greeting() twice?

Options:

A.

Hello!

B.

Hello!!

C.

Hello!Hello!

Buy Now
Questions 12

An algorithm to calculate the positive difference in two given values, x and y, uses the steps shown.

Scripting-and-Programming-Foundations Question 12

What are the two steps of the algorithm that need to be switched to result in success?

Options:

A.

1 and 2

B.

2 and 4

C.

1 and 4

D.

3 and 4

Buy Now
Questions 13

Which kind of languages are C, C++ and Java?

Options:

A.

Markup

B.

Compiled

C.

Interpreted

D.

Machine code

Buy Now
Questions 14

One requirement for the language of a protect is that it is based on a series of method calls.

When type of language is characterized in this way?

Options:

A.

Static

B.

Compiled

C.

Functional

D.

Markup

Buy Now
Questions 15

Which phase of a Waterfall approach defines specifics on how to build a program?

Options:

A.

Design

B.

Testing

C.

Analysis

D.

Implementation

Buy Now
Questions 16

Which characteristic specifically describes an object-oriented language?

Options:

A.

Supports creating programs as items that have data plus operations.

B.

Supports creating programs as a set of functions.

C.

Requires a compiler to translate to machine code.

D.

Can be run on any machine that has an interpreter.

Buy Now
Questions 17

A software developer creates a list of all objects and functions that will be used in a board game application and then begins to write the code for each object.

Options:

A.

Analysis and implementation

B.

Analysis and design

C.

Design and implementation

D.

Design and testing

Buy Now
Questions 18

What is put to output by the following flowchart, if the input is 3.5?

Scripting-and-Programming-Foundations Question 18

Options:

A.

Backlog

B.

Interview

C.

Return

D.

interviewBacking

Buy Now
Questions 19

What would a string be used to store?

Options:

A.

A true/false indication of whether a number is composite.

B.

A positive number between 2 and 3.

C.

The word "positive."

D.

A positive whole number.

Buy Now
Questions 20

A function should return 0 if a number, N is even and 1 if N is odd.

What should be the input to the function?

Options:

A.

Even

B.

1

C.

0

D.

N

Buy Now
Questions 21

A program allows the user to play a game. At the end of each game, the program asks the user if they want to play again.

Which programming structure on its own is appropriate to accomplish this task?

Options:

A.

Nested for loops

B.

One for loop

C.

One while loop

D.

If-else statement

Buy Now
Questions 22

A programmer has been hired to create an inventory system for a library. What is the Waterfall phase in which outlining all the functions that need to be written to support the inventory system occurs?

Options:

A.

Testing

B.

Analysis

C.

Design

D.

Implementation

Buy Now
Questions 23

The steps in an algorithm to find the maximum of integers a and b are given.

Scripting-and-Programming-Foundations Question 23

Which two steps of the algorithm should be switched to make the algorithm successful?

Options:

A.

2 and 4

B.

2 and 3

C.

1 and 2

D.

1 and 3

Buy Now
Questions 24

Which problem is solved by DijkStra’s shortest path algorithm?

Options:

A.

Given an increasing array of numbers is the number 19 in the array?

B.

Given the coordinates of five positions, what is the most fuel-efficient flight pain?

C.

Given two newspaper articles what is the greatest sequence of words shared by both articles?

D.

Given an alphabetized list of face entrants and a person's name, is the person entered in the race?

Buy Now
Questions 25

Which kind of language is HTML?

Options:

A.

Dynamically typed

B.

Markup

C.

Statically typed

D.

Object-oriented

Buy Now
Questions 26

Which phase of a waterfall approach defines specifies on how to build a program?

Options:

A.

Analysis

B.

Implementation

C.

Design

D.

Testing

Buy Now
Questions 27

A program adds a service fee to the total cost of concert tickets when the tickets are printed and mailed to customers. Another service fee is also added if the

Options:

A.

Multiple if statements

B.

If statement

C.

While loop

D.

Do-while loop

Buy Now
Questions 28

Which action occurs during the design phase of an Agile process?

Options:

A.

Determining the functions that need to be written

B.

Determining the goals of the project

C.

Writing the required objects

D.

Deciding on the name of the program

Buy Now
Questions 29

Consider the given function.

Scripting-and-Programming-Foundations Question 29

What is the total output when F (sign, horse) is called 2 times?

Options:

A.

sign and horse sign and horse

B.

sign and horse sign and horse

C.

sign and horse sign and horse

D.

sign and horse and sign and horse

Buy Now
Questions 30

A team of programmers describes the objects and functions in a program that compresses files before splitting the objects. Which Waterfall approach phases are involved?

Options:

A.

Analysis and implementation

B.

Design and implementation

C.

Implementation and testing

D.

Design and testing

Buy Now
Questions 31

Oder the tasks needed to safely replace a lamp's light bulb from first (1) to last (4).

Select your answer from the pull down list.

Scripting-and-Programming-Foundations Question 31

Options:

Buy Now
Questions 32

Scripting-and-Programming-Foundations Question 32

What is the output of the given flowchart if the input is 54?

Options:

A.

55

B.

56

C.

58

D.

60

Buy Now
Questions 33

Which term refers to a function that represents the number of fixed-size memory units used for an input of a given size?

Options:

A.

Space complexity

B.

Linear search

C.

Computational complexity

D.

Runtime

Buy Now
Questions 34

Which characteristic distinguishes a markup language from other languages

Options:

A.

It supports decomposing programs into custom types that often combine with other variable types into more complicated concepts.

B.

It does not perform complex algorithms, but instead describes the content and formatting of webpages and other documents.

C.

It allows variables to change type during execution

D.

It requires fewer variables and variable conversions than other languages because the types can change during execution

Buy Now
Questions 35

What does a function definition consist of?

Options:

A.

The function's argument values

B.

An invocation of a function's name

C.

A list of all other functions that call the function

D.

The function's name, inputs, outputs, and statements

Buy Now
Questions 36

A programmer receives requirements from customers and deciders 1o build a first version of a program.

Which phase of an agile approach is being carried out when trio programmer starts writing the program's first version?

Options:

A.

Testing

B.

Implementation

C.

Analysis

D.

Design

Buy Now
Questions 37

A programming loam is using the waterfall design approach to create an application. Which deliverable would be produced during the design phase?

Options:

A.

A report of customer satisfaction

B.

A list of additional features to be added during revision

C.

A written description of the goals for the project

D.

The programming paradigm to be used

Buy Now
Questions 38

A sample function is shown.

Y = -2 ‘’ x - 2

What is returned for f(-1)?

Options:

A.

-3

B.

0

C.

2

D.

6

Buy Now
Questions 39

Which snippet represents the loop condition expression in the given code?

Options:

A.

Integer f = 1

B.

Put f to output

C.

F < 27

D.

F = f + 2

Buy Now
Questions 40

What is the outcome for the given algorithm? Round to the nearest tenth, if necessary.

Scripting-and-Programming-Foundations Question 40

Options:

A.

5.0

B.

6.0

C.

6.1

D.

8.4

Buy Now
Questions 41

A function determines the least common multiple (LCM) of two positive integers (a and b). What should be the input to the function?

Options:

A.

L only

B.

a * b

C.

a and L

D.

a and b

Buy Now
Exam Name: WGU Scripting and Programming Foundations Exam
Last Update: Apr 24, 2025
Questions: 138

PDF + Testing Engine

$49.5  $164.99

Testing Engine

$37.5  $124.99
buy now Scripting-and-Programming-Foundations testing engine

PDF (Q&A)

$31.5  $104.99
buy now Scripting-and-Programming-Foundations pdf
dumpsmate guaranteed to pass
24/7 Customer Support

DumpsMate's team of experts is always available to respond your queries on exam preparation. Get professional answers on any topic of the certification syllabus. Our experts will thoroughly satisfy you.

Site Secure

mcafee secure

TESTED 01 May 2025