nerdexam
CompTIA

FC0-U61 · Question #554

Given the following pseudocode: Which of the following schools will be chosen for a 16-year-old student?

The correct answer is D. Sandburg. Based on the correct answer and implied pseudocode logic, a 16-year-old student will be chosen for Sandburg school.

Software Development

Question

Given the following pseudocode:

Which of the following schools will be chosen for a 16-year-old student?

Exhibit

FC0-U61 question #554 exhibit

Options

  • ALincoln
  • BWashington
  • CStevenson
  • DSandburg

How the community answered

(71 responses)
  • A
    10% (7)
  • B
    1% (1)
  • C
    4% (3)
  • D
    85% (60)

Why each option

Based on the correct answer and implied pseudocode logic, a 16-year-old student will be chosen for Sandburg school.

ALincoln

Lincoln school would typically be assigned to a different, likely younger, age group based on the implied sequential age-based conditions in such pseudocode.

BWashington

Washington school would be assigned to an age group different from 16, likely an intermediate age group between Lincoln and Sandburg, following typical school assignments.

CStevenson

Stevenson school would also be assigned to an age group different from 16, likely an age range immediately preceding Sandburg in the pseudocode's conditional structure.

DSandburgCorrect

The correct answer indicates that when a student's age is 16, the conditional logic within the pseudocode evaluates to a condition that assigns them to 'Sandburg' school.

Concept tested: Conditional logic and age-based selection

Topics

#pseudocode#conditional logic#programming logic

Community Discussion

No community discussion yet for this question.

Full FC0-U61 Practice