मराठी

Assertion(A): call by value is known as pure method. Reason(R): The original value of variable does not change as operation is performed on copied values.

Advertisements
Advertisements

प्रश्न

Assertion(A): call by value is known as pure method.

Reason(R): The original value of variable does not change as operation is performed on copied values.

पर्याय

  • Both Assertion (A) and Reason (R) are true and Reason (R) is a correct explanation of Assertion (A).

  • Both Assertion (A) and Reason (R) are true and Reason (R) is not a correct explanation of Assertion (A).

  • Assertion (A) is true and Reason (R) is false.

  • Assertion (A) is false and Reason (R) is true.

MCQ
विधान आणि तर्क
Advertisements

उत्तर

Both Assertion (A) and Reason (R) are true and Reason (R) is a correct explanation of Assertion (A).

Explanation:

  • The Assertion is True: A method is considered "pure" if it does its job without changing the outside data (no side effects).
  • The Reason is True: Call-by-value makes a separate copy of the variable for the method to use.
  • The explanation matches: Because the method only works on a copy, the original value never changes. This lack of side effects is exactly what makes it a pure method.
shaalaa.com
  या प्रश्नात किंवा उत्तरात काही त्रुटी आहे का?
पाठ 3: User-Defined Methods - Exercises [पृष्ठ ९०]

APPEARS IN

रूपा पंडित Computer Applications [English] Class 10 ICSE
पाठ 3 User-Defined Methods
Exercises | Q 1. (xi) | पृष्ठ ९०
Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×