Hello.

I've found that "RANDOM (n)" returns some numbers more often than others. the game I was coding needs to select a random number from [0..20] and I get [5..15] much more often than the others, and [5..10] more than [11..15]. It's too obvious for me and I need a more regular frequency. I'm using RANDOMIZE too. [edit]I must say that these numbers are selected few times. In a 'standard' play it searches about 10-15 numbers each player.[/edit]

Is it usual? Is there a way to "normalize" it or another random algorithm available?

I'm using Lazarus 0.9.22 (FPC 2.0.4). If FPC 2.2.0 fixes it, how can I update Lazarus' compiler?

Thanks in advance.