Example of nested if statement, COBOL Programming

Example of Nested if statement:

Illustration:

Consider the following sentence

863_nested if elese statement.png

The nested IF sentence holds two IFs and one ELSE. The IF-ELSE couple has been marked by the number 1 within a circle. The IF marked with 2 within the circle is alone IF without any ELSE. Now it can be simply seen that the above sentence is equal to the following flow chart.

695_nested if elese statement1.png

 

Posted Date: 10/17/2012 2:05:54 AM | Location : United States







Related Discussions:- Example of nested if statement, Assignment Help, Ask Question on Example of nested if statement, Get Answer, Expert's Help, Example of nested if statement Discussions

Write discussion on Example of nested if statement
Your posts are moderated
Related Questions
Illustration of Search verb: To illustrate the other use of SEARCH verb, assume we wish to search the similar tab to find the number of persons whose deposited amount is more

Currency Sign - edit characters for numeric data: $ (Currency Sign): The single currency sign can appear at the leftmost place of a picture. In that situation the $ cha

Illustration of if- else statement: IF OK-BALANCE NEXT SENTENCE ELSE MOVE 2 BALANCE-CODE In this illustration, the OK-BALANCE is a condition name. No action is specific if

PERFORM WITH UNTIL OPTION: The format is as shown below: Illustration:  A) Perform p-3 until i > 5. Here p-3 will be executed whenever i B)  Perform p-2 thru

Environment Division: The Environment Division is the second division in the COBOL source program. It is mainly machine-dependent . The computer and all the peripheral dev

CLOSE STATEMENT: When the processing of a file is completed, then the file may be closed. This is completed with the help of the CLOSE-verb. The form of the CLOSE statement is

Structure of a COBOL Program: Every COBOL program should have the 4 divisions in the order in which they are specified below: 1. Identification division 2. Environment D

Point Location: The position of the decimal point is the other characteristic which can be specified in the case of the numeric data items. If the position is not specified, t

PERFORM STATEMENT:   The PERFORM statement can be used to execute the group of consecutive statements written elsewhere in the program. We refer to this group of statements a

FILE UPDATION: The method of modifying an old file with present information is termed as file updating. Master file: A master file is a file which is used as an author