Note: All the programs listed below can be downloaded directly into Small Basic.  Just import the programs using their published Id.

What started as a fun challenge in our Small Basic Forums, quickly turned into a repository of very interesting programs, all conforming to a 25-line limit.  It is amazing to see enthusiastic participants come up with very creative patterns to embed complex logic in as few lines as possible.

The challenge started with the classic game of Rock/Paper/Scissors, written in 24 lines by Coding Cat and published as CTB433.  This was meant to be just an example for the challenge, but within days, Jason Jacques posted a 9 line version of the same program, published as CTB433-1.  And the race was on.

Recently Rushworks posted a trick to initialize Small Basic arrays in a single line.  Hours later, Davey-Wavey came up with a feature-par version of the original Rock/Paper/Scissors in 3 lines flat!  This version is published as CTB433-2.

25line_1

And using a few tricks and assumptions about the size of the text window, Jason came back and posted the same program in just 2 lines!  It is published as CTB433-5.

As this race was going on, litdev published the Swarm of Bees as MSH031 in 25 lines.25line_2

Simultaneously, Dudeson published a similar program, RRS083 which simulates an atom with the mouse center as the nucleus.  And Grzegorz Tworek, published his Lissajou’s Curve simulator program as GQP876, in 11 lines. 

25line_3

Dudeson went back and improved his atom code to publish RPW587, which runs much faster.

25line_4

Other programs that you’ll find on this forum:

Sudoku Solver

(25 lines)
by Jason Jacques: CGW786

25line_5

Sub Hunt

(25 lines)
by Coding Cat: KDN168
also by Davey-Wavey: KDN168-0

25line_6

Space Invaders

(20 lines)
by Davey-Wavey: XDK444

25line_7