Can we access the a[0] in the array ?

Answers were Sorted based on User's Feedback



Can we access the a[0] in the array ?..

Answer / mandozai

In cobol array starts with 1 not with 0

Is This Answer Correct ?    20 Yes 0 No

Can we access the a[0] in the array ?..

Answer / sandy

Not possible. It will throw compilation error.

Is This Answer Correct ?    8 Yes 2 No

Can we access the a[0] in the array ?..

Answer / jai ho

i think it will send soc4 abend bcoz a[0]
is out of bound.

Correct me

Is This Answer Correct ?    4 Yes 0 No

Can we access the a[0] in the array ?..

Answer / suresh ramaiyan

It will give compilation time error, as the compiler knows
the value of subscript when compile the program.
ex: A[0]

if you are accessing the same by subscript variable, then
it will give run time error.
ex: A[ws-cnt]

Is This Answer Correct ?    3 Yes 0 No

Can we access the a[0] in the array ?..

Answer / i go crazy

The compilation should be done with the compiler option SSRANGE. If NOSSRANGE is used, then we can use A(0) without any issue.

Is This Answer Correct ?    3 Yes 0 No

Can we access the a[0] in the array ?..

Answer / dev

Can u explain why it throws compilation error?

Is This Answer Correct ?    3 Yes 1 No

Post New Answer

More COBOL Interview Questions

How do u write test cases?

0 Answers   IBM,


At the minimum, which division of COBOL is enough to be coded?

3 Answers   CTS,


How does IDMS communicate with CICS?

1 Answers   Covansys, Satyam,


What is amode(24)?

0 Answers  


What is the difference between structured cobol programming and object alternativelyiented cobol programming?

0 Answers  






which is better comp or comp-3 in terms of memory utilization?

6 Answers  


What is the difference between CALL BY VALUE and CALL BY CONTENT?

7 Answers  


How to open and see copy book ?

3 Answers  


Explain about different table spaces.

0 Answers  


If we use GO BACK instead of STOP RUN in cobol?

2 Answers   Temenos,


how to run sub programs using static and dynamic call ...

3 Answers   TCS,


Determine the total no of bytes in the following. 01 rec1. 02 a pic x(6) 02 b redefines a. 03 c occus 6 times pic 9. 02 d occurs 6 times pic 9. 03 e pic x(5) 03 f pic 999.

12 Answers  


Categories