On an interactive ROOT session: Fill an array of 100 000 000 64Bit floating point numbers of the machine independent ROOT typeDouble_t with random numbers. Compute the mean of the array and print it to the console. Note the computation time.
Hint: You can get random real numbers by creating a pointer to an instance of the TRandom class. (The constructor takes one arbitrary integer as initialization.) Then you can call the method TRandom::Rndm() to get a simple pseudo random number uniformly distributed between 0 and 1. For example:
TRandom*R=newTRandom(time(0));// create a pointer to a new instance of TRandom in the heapcout<<R->Rndm()<<endl;