typeof c# code example
Example 1: c# get type of object
//Exact runtime type of the current instance.
object.GetType();
Example 2: c# typeof
string s = "Geeks";
Console.WriteLine(s.GetType());
//Exact runtime type of the current instance.
object.GetType();
string s = "Geeks";
Console.WriteLine(s.GetType());