What is the difference between typeof(foo) and myFoo.GetType()?
Answer Posted / enso
Operator typeof(foo) is used to obtain the System.Type
object for a type at compile time.
myFoo.GetType() is used to obtain the exact run time type of
an object. This method uses reflection.
Is This Answer Correct ? | 11 Yes | 1 No |
Post New Answer View All Answers
How do I get a null pointer in my programs?
What is the process of writing the null pointer?
How can I get the current date or time of day in a c program?
List some applications of c programming language?
What are the advantages of Macro over function?
Why should I prototype a function?
What are the disadvantages of a shell structure?
How many data structures are there in c?
Why does notstrcat(string, "!");Work?
Explain what are global variables and explain how do you declare them?
string reverse using recursion
What is spaghetti programming?
Why can’t constant values be used to define an array’s initial size?
Describe static function with its usage?
Why do we use & in c?