pseudocode:-Pseudocode
and flowcharts are both popular ways of representing algorithms. Pseudocode has
been chosen as the primary method of representing an algorithm because it is
easy to read and write, and allows the programmer to concentrate on the logic
of the problem. Pseudocode is really structured English. It is English that has
been formalised and abbreviated to look like the high-level computer languages.
Pseudo
code conventions:
1. Comments begin with //
and continue until the end of line.
1. Blocks are indicated and matching braces.: {
and }.
2. An identifier begins with a letter
3. Assignment of values to variables is done
using the assignment statement
<variable> :=
<expression>
4. There are two Boolean values true and false
5. Elements of multi dimensional array are
accessed using [ and ].
6. The following looping statements are
employed: for, while and repeat – until
7. A conditional statement has the following
forms:
If <condition> then
<statement>;
8. Input and output are done using the
instructions read and write.
9. There only and one type of procedure:
Algorithm
An algorithm consists of
heading and body. The heading takes the form
Thank you...
ReplyDeleteIt helped...!
ReplyDelete