+ 2
Can anyone explain for me What is dynamic data type in C#? And How to declare a dynamic data type?
6 Answers
+ 1
Check out these....
https://www.google.com/amp/s/www.geeksforgeeks.org/dynamic-type-in-c-sharp/amp/
https://www.tutorialsteacher.com/csharp/csharp-dynamic-type
Hope it helps..
+ 3
Al Muqdaam Al Adawi
THANK U SO MUCH đ
I want ask about what are the ways of passing parameters to a method in C#.
If u know
+ 2
THANK U A LOTđđ Al Muqdaam Al Adawi
+ 1
I can't use private messages for some reason ... I will do my best to help you but I am not that good on C# ... I mainly work on Python so I can help you with the logic and code structure
0
So you have the casual passing like getValue(x)
This is one is allowing the function to use the value of x and nothing
getValue(ref x)
So this passes the value and the reference of x for example you pass x to getValue and inside that function you use the x value as c or y and use it for calculations then return the value to x like this code :
Int x = 1;
x = x +1;
//x = 2
getValue(out x)
So this one is getting the value form the function to x but if you have one out you can use this code:
getValue (int a)
{
a= a+5;
return a;
}
int x = 1;
int y=getValue (x);
But getValue (out y) works like
int x = 1;
int y;
getValue(x,out y);
So it's more efficient to use (out) when you have multiple output from one function
0
Ruqiya My pleasure ... Happy coding time