ICDL Coding Principles study materials
ICDL Coding Principles study resources

ICDL Coding Principles (ICDL) cheat sheet

ICDL Coding Principles · Keep the key ideas within reach.

Quick reference

Coding Principles

  • Sequence: statements execute top to bottom in written order unless a control structure alters the flow.

  • Selection: IF/ELSE and CASE choose a branch by evaluating a Boolean condition; exactly one branch of a two-way IF runs.

  • Iteration: a count-controlled loop repeats a fixed number of times; a condition-controlled loop repeats while or until a test is true.

  • A WHILE loop tests before the body (may run zero times); a REPEAT/UNTIL loop tests after the body (runs at least once).

  • Assignment stores a value in a variable; comparison (equality) tests values and returns a Boolean - do not confuse = with ==.

  • A variable is a named storage location whose value can change; a constant is assigned once and cannot be reassigned.

  • Local variables exist only inside the subprogram that declares them; global variables are visible throughout the program.

  • A function returns a value to the caller; a procedure performs actions without returning a value.

  • Validation checks input against rules (range, type, presence, length) before it is accepted or processed.

Quick reference

Computational Thinking and Problem Solving

  • Decomposition: break a large problem into smaller sub-problems that can be solved and tested independently.

  • Abstraction: remove irrelevant detail and keep only the features needed to solve the problem.

  • Pattern recognition: identify recurring structures or repeated steps so one reusable solution can serve many cases.

  • Algorithm: a finite, ordered, unambiguous set of steps that solves a problem and terminates.

  • Pseudocode is language-independent structured English; a flowchart uses standard symbols - oval for start/end, parallelogram for input/output, rectangle for process, diamond for decision.

  • Trace tables record each variable's value after each step to verify an algorithm's logic by hand.

  • Linear search checks elements one by one (works on unsorted data); binary search repeatedly halves a sorted list and is faster for large sorted data.

  • Test data types: normal (valid, expected), boundary (at the edges of valid ranges), and erroneous (invalid, must be rejected).

  • A dry run executes an algorithm manually with sample inputs to compare actual output against expected output.