Multiple choice technology programming languages

Which of the following is value type

  1. string

  2. class

  3. delegate

  4. struct

  5. interface

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

In C#, value types are stored directly on the stack and contain their actual data. Structs are value types, while classes, delegates, interfaces, and strings are reference types that store references to heap-allocated objects.