Re: enough chatter
-----Original Message-----
From: Bernie Ryan <bwryan at PCOM.NET>
To: EUPHORIA at LISTSERV.MUOHIO.EDU <EUPHORIA at LISTSERV.MUOHIO.EDU>
Date: Sunday, November 14, 1999 8:14 AM
Subject: enough chatter
>The list has hundreds and hundreds of lines of rattle about why the
>
>language should be changed and how I do something in another language.
>
>Some people are on the list to learn programming and want to ask
questions.
>
>Some people on the list tell us about all these wonderful things they
>
>can do but I never see them distribute any code to the list ( maybe
it's
>
>vapor ware ). The real challenge is try to use the langauge the way it
>
>was designed and try to develop aids to help other programmers so they
>
>can gain from your quality code and experienced skills.
>
>Bernie
>
Guilty as charged! I just got tired reading all of these ideas being thrown
around, so I thought that I would mention my ideas, mainly leaving the
language mostly as-is. But then, I had to actually defend my positions and
I got caught up in that.
I actually have written some (simple) code. In fact, here is my version of
a recursive sum function:
-- Sum.e
-- Ver 1.1
-- November 1999
-- Function to (recursively) add all of the elements
-- of a sequence together
-- Usage: a = Sum ( s )
-- Returns the sum of all elements of s.
global function Sum( sequence values )
integer list_length
atom total
object list_element
total = 0
list_length = length( values )
for i = 1 to list_length do
list_element = values[i]
if sequence( list_element ) then
total += Sum( list_element )
else
total += list_element
end if
end for
return total
end function -- Sum
Is there a better solution?
__________________________________________
NetZero - Defenders of the Free World
Get your FREE Internet Access and Email at
http://www.netzero.net/download/index.html
|
Not Categorized, Please Help
|
|