Can anyone here help me with a probability question?

RandomPoster

Platinum Member
May 22, 2017
2,584
1,792
970
Two arrays of 32 integers are generated with random values ranging from 0 to 255 inclusively. Each array is taken separately and used to construct an index array according to the following pattern. The index of the item with the smallest value in the randomly generated array is used to place a value of 0 into the corresponding index array. The second smallest has a 1 and so forth up to an including a value of 31. In the case of a tie, the lower valued index is associated with the smallest original index.

For example, 17,3,6,90,85,97 would produce 2,0,1,4,3,5 and 17,6,6,90,85,97 would produce 2,0,1,4,3,5 according to this pattern.

The number of possible unique randomly generated arrays is 256 to the 32nd power.

1. Assuming the two randomly generated arrays are different, what is the likelihood that they will produce the same index array?
 
I just recalculated my math.....i had a small error in the formula. Sorry about that.

The definitive answer is :


ELEVENTEEN
 
OK I'll take a stab. If you have two arrays that are different then the resulting index arrays would always be different except in the case where the random arrays were all uniform values, like one array of all 3s and one array of all 89s. There are 256 possible arrays like that. But you would have to generate TWO uniform arrays to have the index arrays match.The chances of generating one uniform array would be (256 / 256 **32) so the chances of doing it twice would be that squared.
 

Forum List

Back
Top