Vidyalelo
C# Programming · Q107

Miscellaneous in C Sharp

Programming · C# Programming · question 107

Q107

What will be the output of the following C# code segment? class UnsafeCode unsafe static void Main() int n = 10; void* p = &n; Console.WriteLine(*p); Console.ReadLine();

A.
The program will print 10
B.
Run time error
C.
Compile time error
Answer
D.
Output is the address contained in p

Answer: Option C

Solution

Answer: Option C
No explanation is given for this question Let's Discuss on Board