can u give result for the fallowing example...
05 a pic 9(2)
05 b redifines a pic x(2).
move 'xy' to b.
display a,b.
Answer Posted / shyamala a
SCENARIO 1 :
If we move "XY" TO A then the result will be
1. You will get a compilation warning "** Warning 378 ** Expected digit string as sending operand"
2. display will be Both A and B will have 00.
sCENARIO 2:
iF WE MOVE "xy" TO B then the result will be
1. No compilation/run time error.
2. Display will be both A and B = XY
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What are the different data types in cobol?
Mention the guidelines to write a structured cobol program?
Why do we code s9 (4) comp. Inspite of knowing comp-3 will occupy less space?
Write a program that uses move corresponding.
What is the Purpose of Pointer in the string?
What is Pic 9v99 Indicates in COBOL?
How do you define a variable of comp-1 and comp-2?
How to use the same COBOL program in Batch and CICS on lines? explain with an example
How to get the last record in vsam file in cluster? And how can you get the ksds file records into cobol program?
Discuss about changing dataset name in proc.
How do define dynamic array in cobol.
if we display var1 then what will b displayed in below condition. 77 var1 pic s9(2) value -10. 77 var1 pic s9(2) value -11. " " " -12. " " " -13. -14 ... ... -19.
Describe the cobol database components?
How to know whether the module is dynamical or statistical?
how do you reference the variable block file formats from cobol programs