what is reference parameter?
what is out parameters?
what is difference these two?
Answer Posted / sarun p.t
out is used only to get output from a function.
it means that we cannot give any input using an out
parameter. Whatever value we assign to an out parameter
before calling to a function will be worthless, we need to
assign a value in the called function to our out parameter
before its first usage and if no usage we need to assign a
value before control leave the function.(out can be passed
to function while uninitialized)
ref parameter is used for both input and output. The only
thing is we need to assign a value before its first usage.
ref parameter must be initialized before passing to a
function.
| Is This Answer Correct ? | 2 Yes | 2 No |
Post New Answer View All Answers
What is namespace in oops?
What is static noise?
How do I register my code for use by classic com clients?
Howmany five tracing levels in System.Diagnostics.TraceSwitcher? Why they are using?
Can properties be private in c#?
What is virtual class in C#?
Is c# and c sharp same?
How does aspect oriented programming work?
how dot net compiled code will become platform independent?
What are properties in c#. Explain with an example?
What is task parallel library?
Explain the difference between proc. Sent by val and by sub?
How many bytes is an int in c#?
Can I do things in il that I can't do in c#?
Major difference between Basic httpbinding and WShttpbinding?