Approximating the tail probabilities of the longest run in a sequence of Bernoulli trials