#include typedef void C(void); typedef int R(void); typedef struct{C *up; R *rd;} ob; int main(){ ob o[10]; for(int i = 0; i < 10; ++i) { int c = 0; void inc(void) {++c;}; int r(void) {return c;}; o[i] = (ob){inc, r};}; printf("%d\n", o[3].rd()); o[3].up(); printf("%d\n", o[3].rd()); o[6].up(); printf("%d %d\n", o[3].rd(), o[6].rd()); return 0;}