Consider the following:

77 A PIC 9(10)
77 B PIC 9(10)
77 C PIC 9(19)

MULTIPLY AB BY B GIVING C

Which of the following is true ?

(a) The execution of the above may result in size error.
(b) The execution of the above will result in size error.
(c) The definition of C is invalid resulting in compilation
error.
(d) No error will be thee and the program would proceed
correctly.

Answer Posted / prasanna

A and B are two different variables and there is no
variable declared as AB. Do COBOL has enough knowledge to
identify and multiply the vaiable A and the variable B,
then by B giving the result in C. I don't think so.

Kindly correct me if I am wrong..

Is This Answer Correct ?    7 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

how we sort two input files based on a common column and giving one o/p file please send me the coding logic?

1662


how do you reference the rrds file formats from cobol programs

805


i have 10 names in an array and my name is one of them also array is not in sorted order i need to display my name using index how will i do this

1006


how do you reference the printer file formats from cobol programs

672


how to convert the recors form vsam file to db2 table tru file aid

2767






How to read the 2nd last record of a VSAM file? (The file size is huge and we don't know the key)

2729


How do we get current date from system with century in COBOL?

811


Program A (Normal COBBAT) calling a B Program (DB2COBOL, COBBATDB which is using a VSAM file. its a dynamic call. How we will handle VSAM file decleration in our from JCL from where we are running A PGM. And should we have PLAN for A pGM also. if possible can some one post a sample JCL. Thanks for help in advance.

5070


What is rmode(any) ?

689


What is the difference between comp and comp-3?

704


What is difference between static and dynamic call in cobol?

783


Define static linking and dynamic linking.

670


write a cobol logic. i have file that has 10 records .1 record go to first output file and second record goes to 2 output and etc

718


example for sub strings ? and refernce modifications whit output pls

1850


How can we find that module can be called – whether DYNAMICALLY or STATICALLY?

715