How To move a value to an array using move verb?

Answer Posted / jagan

using PERFORM statements we can move a value to an array
using the MOVE verb.

Below is an example of In-Line Perform where we are moving
a value to an array A

01 Array
05 A PIC X(10) occurs 10 times.

PERFORM VARYING i from 1 by 1 until i > 10
MOVE 1 TO A[I]
END-PERFORM

Is This Answer Correct ?    14 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Difference between array and sub-script ?

1171


Have you used comp and comp-3 in your project? And how?

2014


What are the pertinent COBOL commands?

2632


How arrays can be defined in COBOL?

669


When is inspect verb is used in cobol?

683






How do you get the data to code the BMS macro?

1482


how do you reference the variable unblock file formats from cobol programs

757


Name some of the examples of COBOl 11?

2690


What are the cobol coding sheets?

673


Write a cobol program making use of the redefine clause.

743


what is the difference between COBOL2 AND COBOL390?

2462


What is inspect in cobol ?

808


How to print 10 to 1 if the input have only 10 digit number?

821


What are the different rules of SORT operation?

704


how to move the records from file to array table. give with code example

2229