Show List
Quiz - COBOL - 4
Select the right answer for below questions:
In COBOL, what is the purpose of the “REWRITE” statement?
To delete a record from a file
To update an existing record in a file
To create a new record in a file
To read a record from a file
To update an existing record in a file
Which of the following is not a valid COBOL division?
IDENTIFICATION DIVISION
DATA DIVISION
PROCEDURE DIVISION
FILE DIVISION
FILE DIVISION
In COBOL, what is the purpose of the “MOVE” statement?
To copy data from one variable to another
To perform arithmetic operations on variables
To read input from the user
To write output to a file
To copy data from one variable to another
What is the purpose of the “PERFORM UNTIL” statement in COBOL?
To perform a loop until a certain condition is met
To perform a loop while a certain condition is true
To perform a loop a fixed number of times
To perform a loop based on a table of values
To perform a loop until a certain condition is met
In COBOL, what is the purpose of the “LEVEL” number in a data definition?
To indicate the size of the data item
To indicate the position of the data item in memory
To indicate the data type of the data item
To indicate the hierarchical structure of the data item
To indicate the hierarchical structure of the data item
What is the purpose of the “ACCEPT” statement in COBOL?
To write output to a file
To read input from the user
To perform arithmetic operations on variables
To perform string operations on variables
To read input from the user
In COBOL, what is the purpose of the “RECORD” keyword in a data definition?
To define a data item as a record
To define a record structure
To define a record layout
To define a record separator
To define a record structure
What is the purpose of the “PERFORM VARYING” statement in COBOL?
To perform a loop based on a table of values
To perform a loop until a certain condition is met
To perform a loop a fixed number of times
To perform a loop while a certain condition is true
To perform a loop based on a table of values
Which of the following is a valid COBOL data type?
BOOLEAN
CHAR
DOUBLE
FLOAT
CHAR
In COBOL, what is the purpose of the “INITIALIZE” statement?
To assign an initial value to a variable
To read input from the user
To write output to a file
To perform arithmetic operations on variables
To assign an initial value to a variable
Submit
Retry
{"qz1-434310":"To update an existing record in a file","qz1-434311":"FILE DIVISION","qz1-434312":"To copy data from one variable to another","qz1-434313":"To perform a loop until a certain condition is met","qz1-434314":"To indicate the hierarchical structure of the data item","qz1-434315":"To read input from the user","qz1-434316":"To define a record structure","qz1-434317":"To perform a loop based on a table of values","qz1-434318":"CHAR","qz1-434319":"To assign an initial value to a variable"}
Leave a Comment