Anton Lindqvist, 16 Jan 2017 10:02:
> > Hmm, I see now that my memory is false, ksh93 (available as port) does
> > trace into functions. Still, I'm undecided if we want to change our
> > ksh.
>
> Any thoughts from others on changing the defaults?
just my 2 cents.
when many years ago i found out t
On Fri, Jan 13, 2017 at 10:56:51AM +0100, Otto Moerbeek wrote:
> On Fri, Jan 13, 2017 at 10:20:19AM +0100, Otto Moerbeek wrote:
>
> > On Fri, Jan 13, 2017 at 09:51:51AM +0100, Otto Moerbeek wrote:
> >
> > > On Fri, Jan 13, 2017 at 09:46:54AM +0100, Anton Lindqvist wrote:
> > >
> > > > Consider t
On Fri, Jan 13, 2017 at 10:20:19AM +0100, Otto Moerbeek wrote:
> On Fri, Jan 13, 2017 at 09:51:51AM +0100, Otto Moerbeek wrote:
>
> > On Fri, Jan 13, 2017 at 09:46:54AM +0100, Anton Lindqvist wrote:
> >
> > > Consider the following script which calculates the sum of the first N
> > > integers re
On Fri, Jan 13, 2017 at 09:51:51AM +0100, Otto Moerbeek wrote:
> On Fri, Jan 13, 2017 at 09:46:54AM +0100, Anton Lindqvist wrote:
>
> > Consider the following script which calculates the sum of the first N
> > integers recursively:
> >
> > $ cat >sum.sh < > sum() {
> > [ $1 -eq 0 ] && echo $2
On Fri, Jan 13, 2017 at 09:46:54AM +0100, Anton Lindqvist wrote:
> Consider the following script which calculates the sum of the first N
> integers recursively:
>
> $ cat >sum.sh < sum() {
> [ $1 -eq 0 ] && echo $2 || sum $(($1 - 1)) $(($2 + $1))
> }
>
> sum 5
> !
>
> Executing the script wit
Consider the following script which calculates the sum of the first N
integers recursively:
$ cat >sum.sh