01 ws-p pic 9(2).
01 ws-q pic 9(2) value 01.
01 ws-r pic 9(2) value 99.
p.d.
compute p = q + r
what will be result of p ans(00) but my question is that
how i got 10 on the place of 00.
(truncation will ocuure on right side not left).
please tell me ?
Answer Posted / jayaprabhu
simple always remember that for numeric it's Left
Justification ie TAKE FROM LEFT PLACE FIRST IN LEFT
SO P=100 but as per you it shd be 00 but it will be 10
1 IS FROM LEFT SIDE MOST THEN 00 so if we move as per above
then
p is pic9(02)
so 10 first 1 is moved from left to left then 0 is moved
but since pic 9(02) only to digits get moved
| Is This Answer Correct ? | 0 Yes | 5 No |
Post New Answer View All Answers
How do you differentiate between cobol and cobol-ii?
Why did you choose to work with ibm mainframe cobol programming?
In COBOL programming, what is PERFORM? What is VARYING?
Why would you use find and get rather than to obtain?
What is the default value(s) for an initialize? What keyword will allow for an override of the default?
Can you please let me know the centre name of INS certification in Kolkata.
What are the different open modes available in cobol?
What is the difference between Global and External Variables?
How to know whether the module is dynamical or statistical?
) what is the difference between AID and HANDLE AID?
How do you reference the following file formats from cobol programs?
How do get the result of your program directly on your pc?
i want a program using by if, evaluate , string, unstring, perform, occurs?
input 1 input2 ouput1 output2 output 3 1 re 300 1 re 200 1 re 300 3 rc 500 1 re 200 2 rr 400 1 re 300 2 rr 400 1 rc 400 3 rc 500 1 rc 400 2 rr 700 2 rr 700 5 tt 900 5 tt 900 2 inputs r in flat file and output 1 is matched records,ouptput2 is unmatched of input1,output3 is unmatched of input2! how vl u get the output files using sequential order and to check with each and every records! let me know the procedure division ?
what is the difference between COBOL2 AND COBOL390?