Literals - cobol program, COBOL Programming

Literals:

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
Illustration of Subtract verb: (a) SUBTRACT A FROM B. This illustration means that the value of A will be subtracted from the value of B and the subtracted result will be s

Picture Clause: The picture clause explains the general characteristics of an elementary data item. These characteristics are elaborated below: Class: In COBOL the

PROCEDURE DIVISION statements for the relative files: The statements OPEN, CLOSE, READ, WRITE and REWRITE that are available for sequential files are also available for the re

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

UPDATING OF THE RELATIVE AND INDEXED FILES: The Sequential files are updated by creating a new master file from an existing old master file and a transaction file. Such an Upda

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

PROGRAM FOR INDEXED SEQUENTIAL FILE CREATION (RANDOM MODE): We have to write a program to create an Indexed Sequential File in random mode for Student particulars. Suppose jus

DISPLAY STATEMENT:   The function of the DISPLAY statement is just opposite to that of the ACCEPT statement. It is used to display the low-volume results on the operator's co

PROGRAM FOR CONDITION NAMES: We have to write a simple program to demonstrate Condition names usage.  identification division.   program- id.   environment division.

REWRITE STATEMENT: The REWRITE statement has the format for a relative file as shown below, REWRITE record-name  [ FORM identifier ]