The & means your in argument is to be treated as a reference to an existing istream object, to avoid copying the entire istream you pass in to the function and all its data, which would be inefficient.
The & does not come after "istream", it comes before the name of the variable or function. The same with pointers. For instance: char* a, b;
a is a pointer and b is not. To prevent this counter-intuitive looking code, always put the & or * closer to the variable name than to the type: char *a, b;
This way it is easy and natural to say that a is a pointer and b is not.
Thus, your function can be written better as:
6 7 8 9 10
istream &read(istream &in)
{
in >> num;
return in;
}
@idratex: istream is not allowed to be copied, it would give you an error about not being able to access the copy constructor or operator=