Question discussion

In C#, which keyword is used to prevent a class from being inherited?

922Medium DSSSB TGT Computer Science 0 replies 1 views
0

In C#, which keyword is used to prevent a class from being inherited?

  • Asealed
  • Babstract
  • Cstatic
  • Dvirtual
Correct answer: A

Explanation

A class declared 'sealed' cannot be used as a base class.

Discussion 0

Nobody has replied yet. Start the discussion!