Programs in Maple exploring stopped binary sequences
Say that a binary sequence, indexed from 1, is "stopped at time n" if every entry in (n/2,n] is 0. The stopping time of a binary sequence is the least n for which the sequence is stopped at time n, or ∞ if no such n exists. These programs construct and explore the set of sequences of length n and stopping time n.