Joe-

Your equation for the expected value of a geom. RV is correct. However, the way you explained your logic could possibly be wrong. This comment is nit-picky for clarification.

The expected value of X, E[X], is the number of times on average you would have to try and pick a key, before you actually chose the right one. The real number of times it takes to chose the right key could be one time(if you were right the first try) or it could be 100 million(if you have really bad luck). The key point is that expected values have no bearing on the actual outcome of an experiment.

Alumni Liaison

Basic linear algebra uncovers and clarifies very important geometry and algebra.

Dr. Paul Garrett