ProgrammingSequence, selection, iteration, procedures, functions, modules, parameters, compilers, interpreters

Syllabus Detail

  • Pseudocode to represent a solution 11 ATAR

Background

  • Pseudocode can be seen as non-technical programming
  • It exists as documentation for planning out and assessing an algorithm
  • We often write pseudocode on pen and paper, although it is generally up to the author's personal preference
  • Pseudocode is never compiled or interpreted - it is purely used as a high-level description of the process(es) for human interpretation
  • Pseudocode (along with trace tables) can be used as a proof of concept or solution for application

 

Examples


1.1 Return the student's academic status based off their mark [English orientated]

IF Student's grade is greater than or equal to 65
    PRINT "Passed"
ELSE
    PRINT "Failed"

1.2 Return the student's academic status based off their mark [Programming orientated]

var = Input("Student's grade")
IF var >= 65

    PRINT("Passed")
ELSE
    PRINT("Passed")

 

2.1 Determine the percentage of student's that have passed [English orientated]

Set passCounter to 0
Set totalStudents to 0

FOREACH Student
    ADD 1 to totalStudents
    IF Student's grade is greater than or equal to 65

        PRINT "Passed"
        ADD 1 to passCounter
END FOREACH

SUBMODULE: percentageOfPasses(totalStudents, passCounter)
Set percentageTotal to 0

percentageTotal = (passCounter divided by totalStudents) times 100

Return percentageTotal

 

2.2 Return the student's academic status based off their mark [Programming orientated]

passCounter = 0
totalStudents = 0

FOREACH Student
    totalStudents += 1
    IF(studentGrade >= 65)
        PRINT "Passed"
        passCounter += 1
END FOREACH

SUBMODULE: percentageOfPasses(totalStudents, passCounter)
percentageTotal = 0

percentageTotal = (passCounter / totalStudents) * 100

Return percentageTotal

 


Further Research

 

Worksheet and Practice (yet to be added)

Found an error or have an enhancement? Please let us know via this contact form