How are parameters passed in C#? Are they passed by reference or by value?

By default, all parameters are passed by value in C#. Parameters are only passed by reference if you explicitly include an out or ref modifier. However, you need to be aware that when the type of the parameter is a reference type, you’re passing a reference rather than an actual object. For more information, see my article on parameter passing and the C# Programmer’s Reference.

[Author: Jon Skeet]