Pseudo Code Damian Gordon Pseudocode The first thing

  • Slides: 12
Download presentation
Pseudo. Code Damian Gordon

Pseudo. Code Damian Gordon

Pseudocode • The first thing we do when designing a program is to decide

Pseudocode • The first thing we do when designing a program is to decide on a name for the program.

Pseudocode • The first thing we do when designing a program is to decide

Pseudocode • The first thing we do when designing a program is to decide on a name for the program. • Let’s say we want to write a program to calculate interest, a good name for the program would be Calculate. Interest.

Pseudocode • The first thing we do when designing a program is to decide

Pseudocode • The first thing we do when designing a program is to decide on a name for the program. • Let’s say we want to write a program to calculate interest, a good name for the program would be Calculate. Interest. • Note the use of Camel. Case.

Pseudocode • The first thing we do when designing a program is to decide

Pseudocode • The first thing we do when designing a program is to decide on a name for the program. • Let’s say we want to write a program to calculate interest, a good name for the program would be Calculate. Interest. • Note the use of Camel. Case.

Pseudocode • So we start the program as: PROGRAM Calculate. Interest:

Pseudocode • So we start the program as: PROGRAM Calculate. Interest:

Pseudocode • So we start the program as: PROGRAM Calculate. Interest: • And in

Pseudocode • So we start the program as: PROGRAM Calculate. Interest: • And in general it’s: PROGRAM <Program. Name>:

Pseudocode • Our program will finish with the following: END.

Pseudocode • Our program will finish with the following: END.

Pseudocode • Our program will finish with the following: END. • And in general

Pseudocode • Our program will finish with the following: END. • And in general it’s the same: END.

Pseudocode • So the general structure of all programs is: PROGRAM <Program. Name>: <Do

Pseudocode • So the general structure of all programs is: PROGRAM <Program. Name>: <Do stuff> END.

Components • Sequence • Selection • Iteration

Components • Sequence • Selection • Iteration