Re: EU script
- Posted by Chris Bensler <bensler at telus.net> Aug 12, 2001
- 484 views
That does look very familiar, but my intention is to have a scripting engine that can execute any EU code file. including 'includes'... maybe, hmm, don't know yet.. So someone could effectively write a stand alone eu program and run it as a script. Chris > Have you thought about imbedding Lua? That's exactly what it was designed > for, > and Lua looks so much like euphoria it's spooky. Even down to the -- > comments. > Example follows: > > -------------------------------- > -- 99 bottles of beer ~ Lua 4.0 > -------------------------------- > function bottle(n) > if n==0 then return 'no more bottles' > elseif n==1 then return '1 bottle' > else return n..' bottles' > end > end > > n=99 > while (n > 0) do > print (bottle(n)..' of beer on the wall,') > print (bottle(n)..' of beer.\nTake one down,\npass it around,') > n = n - 1 > print (bottle(n)..' of beer on the wall.\n') > end > > Regards, > Irv >