Difference between ref and out keywords in C#
Ask by Niraj Kumar Mishra
Updated 19 Sep 2020
ref and out both allow the called method to modify a parameter. The difference between them is what happens before you make the call.
ref means that the parameter has a value on it before going into the function.
out means that the parameter has no official value before going into the function.