1) Creating a single type containing all the infomation they're interested in and returning that (e.g. a struct)
2) Returning an instance of some aggregate container type, or other such set of data (e.g. a std::pair, or a tuple, or a vector of some type, etc.)
3) Passing the function references to variables, which the function will then alter. When the function is finished, the caller can then just examine those variables to see what the function did.
Okey, you guys got me thinking about the struct thing, but in a different way, which you couldn't know because I did not specify my question enough.
Suppose I create a data struct on the very top of my program, so a general struct, with an array to it as wel, like this:
struct{
int reward;
double resptime;
}data[NTRIALS];
If now in my trial function I were to change the value of both reward and resptime, would they then keep there new values as the program leaves the trial function? Without having to return anything, so just a void function?