Examveda

What is the correct syntax to declare a method named Display inside a class named Person in C#?

A. Display { public void }

B. public void Display() { }

C. void Person::Display() { }

D. None of the above

Answer: Option B


Join The Discussion

Related Questions on Classes and Objects in C Sharp