Tuesday, July 24, 2012

Pseudo Codes

Here are some notes I made while Sir was explaining to us what Pseudo Codes were.

Type of Enlgish- common words
Infromed structure- so it does not follow a set of rules
This tries to describe the algorithim in text that resembles code although may not be

Psuedo Code Commands
Here are some fo the Psuedo Codes we did with Mr Lenon.

If...then
else
These are examples of selection commands, since you are required to select something.

Some Keywords that should be used

Repeat .. until } this is an example of a repetition command
an example of when this command is used includes : add one until a total of 50

Protest Repetition
Post Test Repetition
Intialize means set to a certain value
Input means get a value
Print means output to hard copy

Writing a pseudo code for filling a bath with water:

Task : Writing a code for "filling a bath with 80 L"


No comments:

Post a Comment