PERFORM subroutine USING var. The var field is known as what type of parameter?

  1. Formal

  2. Actual

  3. Static

  4. Value


Correct Option: B

AI Explanation

To answer this question, we need to understand the different types of parameters used in subroutines.

In this scenario, the PERFORM statement is used to call a subroutine and the keyword "USING" is used to pass a parameter to the subroutine. The parameter in question is referred to as "var".

The different types of parameters used in subroutines are:

A. Formal - A formal parameter is a placeholder in the subroutine definition that represents the data passed to the subroutine. In this case, "var" is not the placeholder in the subroutine definition, so it is not a formal parameter.

B. Actual - An actual parameter is the actual data or variable passed to the subroutine during the subroutine call. In this case, "var" is the actual parameter being passed to the subroutine, so it is an actual parameter.

C. Static - Static refers to a storage class in programming languages and is not directly related to subroutine parameters. It is not the correct answer in this context.

D. Value - Value is a term that can be used to describe different aspects of programming, but it is not specifically related to subroutine parameters. It is not the correct answer in this context.

Therefore, the correct answer is B) Actual. The var field is known as an actual parameter because it is the actual data or variable passed to the subroutine during the subroutine call.

Find more quizzes: