Literals - cobol program, COBOL Programming


The actual values can too appear in a program. These values are termed as literals. For illustration, the statement MOVE 0 TO TOTAL indicates that the value zero will be moved to the variable TOTAL. This constant 0 that is used in the body of the statement is a literal.

A data name may have various values at various points of time while a literal means the specific value that remains unchanged throughout the execution of the program. For this reason the literal is frequently termed as a constant. Furthermore the literal is not given a name; it presents itself and does not need to be defined in the Data Division.

There are 3 kinds of literals:

a) Numeric

b) Nonnumeric.

c) Figurative constants




Posted Date: 10/16/2012 3:31:12 AM | Location : United States

Related Discussions:- Literals - cobol program, Assignment Help, Ask Question on Literals - cobol program, Get Answer, Expert's Help, Literals - cobol program Discussions

Write discussion on Literals - cobol program
Your posts are moderated
Related Questions
GIVING    file-name-5. The input files to be merged through the MERGE statements which are specified in the USING phrase. These files should be sequential files and should be

B (Blank Insertion) : The occurrence of a B anyplace in the picture will insert a space character in the edited data. There can be more than one B in the picture. Examples:

Illustration of nested if statement: Consider the nested sentence which is as shown below: The IF-ELSE pairs in this sentence can be detected by applying the rule whic

READ STATEMENTS: The common format for the read statements is as shown bellow. Format 1: READ file-name RECORD [ INTO   identifier ] [  ;  AT   END     imperative-s

Example of Redefines clause: This illustration describes a sales record that may either contain the total amount of sale or the quantity (QTY) and UNIT-PRICE. The aim of such

Rules for apply for the condition name: The rules below apply for the condition name. (i) The Condition names should be explained at level 88. The level number starts in ma

Example of Perform statement: PERFORM BEGIN-CALCULATION THRU END-CALCULATION. Assume, BEGIN-CALCULATION and END-CALCULTION is paragraph names. The execution of the PERFORM

FILE STATUS clause: This clause has been involved in the above syntax for completeness. The ORGANIZATION, REVERSE, ACCESS and STATUS clause can be specified in any order.

The LENDER Bank offers mortgages on homes valued up to $500,000. The required down payment is calculated as follows: 4% of the first $60,000 borrowed 8% of the next $30,000 borro

RELATIONAL CONDITION:   We know that a relational condition specifies a comparison between two operands and has the form.     Operand-1    relational-operator   operand-2