Randal Schwarts's challenge !

Reading Randal Schwarts' excellent comments, I had to take the last paragraph's challenge and rewrite his Squeak
solution into gst!.

" Randal Schwartz's modified md5 squeak code modified to gst"

 desiredLength := 20.
 sourceCharacterSet := '0123456789abcdefghijklmnopqrstuvwxyz'.
 str := String new: desiredLength.
 str := ((1 to: desiredLength) collect: [:each | sourceCharacterSet atRandom]) asString.
 str printNl.

One more line to delete!

" Randal Schwartz's modified md5 code "

 desiredLength := 20.
 sourceCharacterSet := '0123456789abcdefghijklmnopqrstuvwxyz'.
 s := ((1 to: desiredLength) collect: [:each | sourceCharacterSet atRandom]) asString.
 s printNl.

User login