// Ex550.cc // Sec. 5.5 of lecture // general type definitions #include #include main() { // new types typedef short int Boolean; typedef char Text[100]; typedef struct { double x,y,z; } Point3D; // new variables Boolean a,b; Text eintrag; Point3D pts[10], p = {1,2,3.45}; // init strcpy(eintrag,"A beautiful code"); pts[0] = p; a = (p.x == pts[0].x); // boolean b = !a; // boolean // output cout << endl; cout << eintrag << endl; cout << "p = " << p.x << " , " << p.y << " , " << p.z << endl; cout << "a = " << a << endl; cout << "b = " << b << endl; }