Yes, initializing the value will do this.
struct pod { int a, b; char c; double d; }; pod myPod = pod();
C ++ 11 will also allow you to assign default values ββin a class definition, but Visual Studio does not yet support this.
struct pod { int a = 0, b = 0; char c = 0; double d = 0.0; }; pod myPod;
source share