Free Online Flashcard Deck

01. Introduction to Programming and Algorithmic Problem Solving Free Online FlashCards

Study 01. Introduction to Programming and Algorithmic Problem Solving with 12 free online flashcards. Review key terms, definitions, and concepts with this interactive flashcard deck.

12 cards
01
Front

What is an algorithm?

Back

An algorithm is a finite, ordered procedure that specifies inputs, processing steps, outputs, termination, and correctness.

02
Front

How does a program differ from an algorithm?

Back

A program is a concrete implementation of an algorithm using the formal rules of a particular programming language.

03
Front

What determines whether code has valid form?

Back

Syntax is the grammar of a programming language: the rules that determine whether code has a valid form.

04
Front

What is control flow?

Back

Control flow is the order in which program statements execute. Sequences, conditionals, loops, and function calls shape that order.

05
Front

What is a variable?

Back

A variable is a named reference to a value; assignment gives it a value or changes the value it refers to.

06
Front

What value does a Boolean expression produce?

Back

A Boolean expression evaluates to True or False and is commonly used to control program flow.

07
Front

When is p and q true?

Back

The expression p and q is true only when both p and q are true.

08
Front

What is a function?

Back

A function is a named, reusable block of code that may accept parameters and produce an output with return.

09
Front

What is decomposition in problem solving?

Back

Decomposition breaks a task into smaller operations, reducing cognitive complexity and often suggesting useful functions.

10
Front

What is the purpose of testing?

Back

Testing compares a program’s actual behavior with expected behavior using normal, boundary, special, and invalid cases.

11
Front

What prerequisite does binary search have?

Back

Binary search requires sorted input because it uses ordering to eliminate half of the remaining search range after each comparison.

12
Front

What is binary search’s worst-case time complexity?

Back

Binary search has worst-case running time O(log n), because it approximately halves the remaining search range at every iteration.