You have the following line of code.
You need to create an object named obj that has a type of type1.
Which line of code should you use?
A.
B.
C.
D.
You have the following line of code.
You need to create an object named obj that has a type of type1.
Which line of code should you use?
A.
B.
C.
D.
Correct “D”
Yes D. Activator.CreateInstance(type) returns an object. See: https://docs.microsoft.com/en-us/dotnet/api/system.activator.createinstance?view=netframework-4.8
D correct
D