consider the following piece of code
01 GROUP-ITEM
05 AMOUNT-1 PIC 99V9 USAGE COMP VALUE 50
05 AMOUNT-2 PIC 9(4)V99 USAGE COMP
MOVE ZERO TO GROUP-ITEM
ADD 50 TO AMOUNT-1
what will be the content of AMOUNT-1?
a.50
b.100
c.0
d.unpredictable
Answer Posted / suresh
hi naveen,
Actually we are moving 0 to group-item so it will become
zero and adding 50 to amount-1. Hence Amount-1 is 50.
please correct me if i am wrong.
| Is This Answer Correct ? | 5 Yes | 1 No |
Post New Answer View All Answers
Can we redefine the field of x(200) to less than 200?
Differentiate between structured cobol programming and object-oriented cobol programming.
explain sorting techniques in cobol program?
How to print 10 to 1 if the input have only 10 digit number?
What are various search techniques in cobol? Explain.
What is comp-1 and comp-2?
What is the default value(s) for an initialize and what keyword allows for an override of the default?
What are the different rules of SORT operation?
How to change size of Initial number of records to *NOMAX for ALL PF files from perticular library, how can I do that
how do you reference the ksds vsam file formats from cobol programs
Explain sorting techniques in cobol program? Provide the sort file definition, the sort statement, its syntax and meaning
here is my requirement A1 is alphanumeric with value 'A1B2C3D4' as defined below 05 A1 PIC X(8) VALUE IS 'A1B2C3D4' but i need to have A2,A3 as ABCD & 1234 repectively...... A2 = ABCD A3 = 1234 Can you please explain me what are the different ways to do it?
please..could u give an example about USAGE IS POINTER ..and explain why and when we use it ?
What is difference between static and dynamic call in cobol?
How can i load all the data from a file to Table (array) in cobol.How i manage the occurs clause with out reading the file.Any options avilable ? Please can any one help me it is urgent?