Multiple choice technology programming languages

which of the following is correct?

  1. Structure is a value type and Class is a reference type

  2. Class is a value type and Structure is a reference type

  3. Structs can't have destructors, but classes can have destructors

  4. Class can have implementation inheritance, but Structs cannot have it

  5. Structs can have implementation inheritance, but Class cannot have it

Reveal answer Fill a bubble to check yourself
A,C,D Correct answer
Explanation

Structures are value types stored on the stack, while classes are reference types stored on the heap. Structs cannot have destructors (finalizers) and do not support implementation inheritance. Classes support both inheritance and destructors.