Nadya,
The answer to your question is
p = (2^n - 1)/(2^n)
because any one even number (i assume you're using integers) will make the product even.
More simply, it's
p = 1 - (0.5)^n
Because the probability of picking all odd numbers is (0.5)^n, and the probability of getting an even product is 1 - (probability of picking all odd numbers)
What John hasn't taken into account in his formula is that it only works if each of the outcomes is equally likely (like rolling dice or whatever [except in Vegas :)]). If the outcomes have a different likelyhood, then you need to weight each outcome in proportion.
Hence, on some days, the chance of precipitation is > 0.5 and on some days it is less. There are sophisticated models used to estimate the likelyhood of weather (none of which work very well in my experience <g>) and so the forecasters think they can do better than just p=0.5 as John would have.
Cheers,
Andrew
>Hi John,
>>>>>
>>> May I ask you a very simple question, but you should answer in just one second:
>>>What's the probability, that the product of 2 random numbers in even? Now 3 numbers, now 4...
>>
>>The same formula should apply - possible outcomes over population.
>
>So, you answer is ????????
>And now think ...
If we were to introduce Visual FoxBase+, would we be able to work from the dotNet Prompt?
From Top 22 Developer Responses to defects in Software
2. "It’s not a bug, it’s a feature."
1. "I thought I fixed that."
All my FoxTalk and other articles are available on my
web site.
Unless specifically identified otherwise, anthing posted here is purely my opinion and may or may not reflect the policies or practices of Microsoft.