ExamGecko
Question list
Search
Search

List of questions

Search

Related questions











Question 50 - CTAL-TTA discussion

Report
Export

Below is the pseudo-code for the bingo program:

The bingo program contains a data flow anomaly. Which data flow anomaly can be found in this program?

A.
Variable 'MIN' is not assigned a value before using it.
Answers
A.
Variable 'MIN' is not assigned a value before using it.
B.
Variable 'AB is defined but subsequently not used.
Answers
B.
Variable 'AB is defined but subsequently not used.
C.
An invalid value is assigned to variable 'B'.
Answers
C.
An invalid value is assigned to variable 'B'.
D.
The hard-coded value '2' should not be used.
Answers
D.
The hard-coded value '2' should not be used.
Suggested answer: A

Explanation:

In the provided pseudo-code for the Bingo program, the variable MIN is used in the statement MIN = MIN + A without being initialized with a value beforehand. This represents a classic 'use before define' anomaly, as the variable MIN must have an initial value before any operation like addition can be performed on it.

asked 18/09/2024
Karsten Heimers
41 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first