#include #include struct mystruct { int n; }; struct father { int test; struct mystruct M; struct mystruct N; }; int main() { struct father* F = (struct father*) malloc(sizeof(struct father)); F->test = 42; F->M.n = 23; F->N.n = 11; int* p = &F->M.n; int* q = &F->N.n; printf("test: %d, M.n: %d, N.n: %d\n", F->test, *p, *q); free(F); printf("test: %d, M.n: %d, N.n: %d\n", F->test, *p, *q); return 0; }