{'fraction_non_alphanumeric': 0.013254786450662739, 'fraction_numerical': 0.004418262150220913, 'mean_word_length': 4.762711864406779, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
An Algorithm of a Longest of Runs Test for Very Long Sequences of Bernoulli Trials

A new algorithm of computing statistics of a longest of runs test is proposed for the case of equal probability Bernoulli trials processes. The algorithm is founded on the analysis of the event tree diagram, which has shown the role of Fibonacci numbers of higher orders in counting the number of outcomes of interest in the sample space. The proof by induction is given. Compared to the classical combinatorial formulas, the proposed algorithm provides the error-free exact probabilities and makes possible the processing of very long binomial data sets (up to 10 3 ) on contemporary computers.