[Oberon] Multiple RETURN in a procedure
Chris Burrows
cfbsoftware at gmail.com
Sun Oct 23 23:45:47 CEST 2022
On Mon, Oct 24, 2022 at 3:28 AM Skulski, Wojciech <skulski at pas.rochester.edu>
wrote:
>
> > PROCEDURE min (x,y: INTEGER) : INTEGER;
> > BEGIN IF x < y THEN RETURN (x) ELSE RETURN (y) END END min;
>
FTR, your original code would have been smaller and more efficient if you
had used Oberon's built-in MIN function instead of writing your own.
Regards,
Chris Burrows
CFB Software
https://www.astrobe.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.inf.ethz.ch/pipermail/oberon/attachments/20221024/b0a86229/attachment.html>
More information about the Oberon
mailing list