Re: Begin...End; Begin...End.
On Thu, 16 Jan 1997, Izchak Aronov wrote:
>
> Hi,again.
> You know, I think I'm gonna begin my programming lessons on Euphoria.
> I have only little problems,like how begins the main block of the program on
> this language (like begin end. and TP)? How begin the block of a function or
> a procedure?
>
> Thank you very much.
> Izchak Aronov.
>
Functions are like this:
function apples(atom a, atom b, sequence blah)
:
:
: do whatever functions do
return (result1,result2...)
end function
Procedures are like this:
procedure update_screen()
:
:
: do whatever your procedure does
:
end procedure
pretty much anything that isn't inside the function..end function and
procedure..end procedure (or type..end type) is program and is executed in
the order it is in the source code beginning to end.
You can stick program code around your functions and procedures if you
want to. Its pretty sloppy, but you can do it if you want to.
Michael Packard
Lord Generic Productions
lgp at exo.com http://exo.com/~lgp
A Crash Course in Game Design and Production
http://exo.com/~lgp/euphoria
|
Not Categorized, Please Help
|
|