In a sequence of independent Bernoulli trials the probability for success in the kth trial is pk, k = 1, 2, …. The number of strings with a given number of failures between two subsequent successes is studied. Explicit expressions for distributions and moments are obtained for the case in which pk = a/(a + b + k − 1), a > 0, b ≥ 0. Also, the limit behaviour of the longest failure string in the first n trials is considered. For b = 0, the strings correspond to cycles in random permutations.