40.7k views
0 votes
.When an argument is passed ______________, the called method can access and modify the caller’s original data directly.

a.either by value or by reference

b.by value

c.using keyword ref

1 Answer

5 votes

Answer:

c.using keyword ref

Step-by-step explanation:

In C# when we have pass any variable by reference we use the ref keyword. When we pass a variable by reference in the function the changes done in the function are directly happening on the original variables.

When a variable is passed by value a copy of these variable is created in the function and the operation is done on those copies.No changes can be seen on the original variables.

Hence the answer is option c.

User Msk
by
7.8k points