Is it something to do with the periodicity of rand()? I can re-write with drand48 or a more modern RNG and run it if you wish. I doubt the result will be much different. In the mean time, here are the requested results:
$ ./a.exe
13660, 0.124671
1000000, 0.120268
2000000, 0.120455
3000000, 0.120313
4000000, 0.120312
5000000, 0.120361
6000000, 0.120417
7000000, 0.120509
8000000, 0.120519
9000000, 0.120577
10000000, 0.120642
Bookmarks