Domanda di colloquio di BioWare

What's the difference between a class and struct in C#? In C++?

Risposta di colloquio

Anonimo

13 mar 2015

The difference between class and structure in C# is that you use structs to define value types (as opposed to reference types declared by classes). In C++, a struct is the same thing as a class with a default accessibility level of public.

1