Illustration of the abbreviation - compound condition, COBOL Programming

Illustration of the abbreviation:

A few illustration of the abbreviation are given below:


The compound condition 


can be abbreviated to


Here, the second appearance of the general subject AMOUNT has been absent.


The compound condition

CARD-CODE    =    3    OR    CARD-CODE   =   5   OR  CARD-CODE   =  7

may be abbreviated to

CARD-CODE   =  3   OR   5   OR   7

In this, the subjects as well as the relational conditions in the given compound condition are similar. Accordingly, the second and third appearances of the subject and the relational condition have been absent.

The consecutives relational conditions which are being considered for the abbreviation may also hold the word NOT. In this situation the interpretation of the abbreviated condition can become ambiguous. To solve the ambiguity the rule below has been recommended in the ANS I standard. The term NOT preceding a relational operator in an abbreviated condition is considered part of the relational operator. Or else, NOT is considered to be a logical operator negating the condition preceded by it. The illustration below can help to understand this rule.


The condition


is interpreted to be the abbreviation of a compound condition AGE LESS THAN 30 AND AGE NOT LESS THAN 20 OR AGE NOT LESS THAN 40

This is because the NOT precedes the relational operator LESS THAN in the abbreviated condition and as such it is interpreted to be a section of the relational operator NOT LESS THAN.

Posted Date: 10/17/2012 1:50:00 AM | Location : United States

Related Discussions:- Illustration of the abbreviation - compound condition, Assignment Help, Ask Question on Illustration of the abbreviation - compound condition, Get Answer, Expert's Help, Illustration of the abbreviation - compound condition Discussions

Write discussion on Illustration of the abbreviation - compound condition
Your posts are moderated
Related Questions
INPUT-OUTPUT SECTION: This section holds information regarding the files to be used in the program. There are 2 paragraphs in this section- FILE-CONTROL & I-O-CONTROL. The

Group Item as Operand in the Relational Condition: Whenever an operand of a relational condition is the group item, the item is then considered to be an alphanumeric field. Th

Numeric -   Literals : The numeric literal can be created with the help of digits only. It can have a sign (+ or -) and can also have a decimal point. If no sign is specifi

File Activity: The file activity is a measure of the proportion of records processed during an update run. Therefore we define the activity ration as shown below. Activi

Occurs Clause: Let us establish tables with the help of an illustration. Assume that there are ten different types of income-tax rates that are read from some input medium and

DELETE STATEMENT: The format of the delete statement is as shown below: DELETE   file-name RECORD   [  ;   INVALID   KEY  imperative-statement  ] Whenever the ACCESS MOD

I need help with a COBOL programming assingment. I have started the program but I need help completing the program. I have 5 errors. Here is the question. 10. Suppose your company

Illustration of Divide verb: (a) DIVIDE 5 INTO A. If the value of A is 20, then after execution of this statement the value of A will be 4. The older value of A will be los

INDEXED TABLES: The OCCURS clause that is used to define tables can optionally have an INDEXED phrase. This phrase involves the names of data items which are to be used as sub

STATEMENTS FOR SEQUENTIAL FILES: A basic operation on a file includes the reading and writing of its records. Whenever the file is sequential, there are three verbs for the