Parameter type of C# method:
1. By value : defualt type
public int Add(int num1, int num2)
...
2. By reference by in&out value : use "ref"
public void Add(int num1, int num2, ref result)
...
3. By reference by out only : use "out"
public void Add(int num1, int num2, out result)
...
No comments:
Post a Comment