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 u handle errors in BMS macro
Write a program to enter and display the names of students in a class using the occurs clause.
What is the difference between PIC 9.99 and 9v99 in COBOL?
Is it possible that the redefines clause has different picture clauses compared to the one it redefined?
What is cobol?
Explain how to differentiate call by context by comparing it to other calls?
What is the difference between next sentence and continue in cobol programing language?
Explain about different table spaces.
What is the difference between a binary search and a sequential search what are the pertinent cobol?
What is a scope terminator give example?
In COBOL, what is the different between index and subscript?
How to find out the closest prime number of an input number? I believe it has something to do with SEARCH and COBOL Linear Array.
Difference between array and sub-script ?
What is the difference between comp and comp-3?
How do you get the data to code the BMS macro?