Within C, say I have a number of variables, floats, integers etc, is there a way that I can group them all into one object, lets call it a system, and then create N copies of such an object.Further, is there a way to assign to each copy of the system a particular value of a variable T such that each system has a different but predetermined T? I am very new to C programming so don't quite know where to start, your help is much appreciated. 
grouping variables into a system in C?
c;variables
Quick and dirty way to do it:typedef unsigned int t_t;struct your_thing {    int a;    float b;    char z[20];    t_t t;};struct your_thing copy_thing(struct your_thing thing) {    static t_t counter = 0;    thing.t = counter++;    return thing;}Example:struct your_thing a = { ... };a = copy_thing(a); // needed to initialize a.tstruct your_thing b = copy_thing(a);b.t is now different than a.t, and as long as all copies of the struct are made with copy_thing() they will never collide.This is not a very good way of doing this, though, since the static variable is global and not thread safe. I can't see why you would want to do this. What you probably have here is the XY problem.