Simple Sequence Generation Algorithm v0.3 (old program written in high school)