what does this mean?

I have some code, if youve helped me recently you may recognize it.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#include <iostream>
#include <ctime>
#include <random>
#include <string>

using namespace std;

int main()
{
    int X;

    time_t T;
    time (&T);
    srand(T);

    X = rand() % 11;

    cout << X << endl;
}


what is the & in time (&T) doing? what is it for?
It it passing the address of the variable T. Read up on pointers to learn what the point of it is.
Topic archived. No new replies allowed.