Длинноник, не вижу рандома вообще.
function RandomSplit( A, parts, min ) {
var numbers = [];
for ( var i = 0; i < parts; i++ ) {
var part = ( A / (parts - i) - min) * Math.random() + min;
part = Math.round( part );
numbers[i] = part;
A = A - part;
}
for ( var i = 0; i < numbers.length; i++ )
numbers[i] += A / parts;
return numbers;
}
var counter = [0, 0, 0];
for (var i=0; i<10000; i++) {
counter[RandomSplit(1, 3, 0).indexOf(1)]++;
}
alert(counter);