Re: make i:j equivalent to [(k,k=i,j)]?
- From: Paul van Delst <Paul.vanDelst@xxxxxxxx>
- Date: Tue, 31 Oct 2006 08:33:26 -0500
beliavsky@xxxxxxx wrote:
Would it break anything in Fortran to make an expression
i:j
equivalent to the array constructor
[(k,k=i,j)]
The R programming language, which has a matrix language similar to
Fortran, effectively does this. I know that "not breaking" is not by
itself sufficient reason to add "syntactic sugar" to the language.
How 'bout some new operators:
i.upto.j == (/(k,k=i,j)/)
and
j.downto.i = (/(k,k=j,i,-1)/)
?? :oD
cheers,
paulv
p.s. Hi Bil! :o)
--
Paul van Delst Ride lots.
CIMSS @ NOAA/NCEP/EMC Eddy Merckx
Ph: (301)763-8000 x7748
Fax:(301)763-8545
.
- Follow-Ups:
- Re: make i:j equivalent to [(k,k=i,j)]?
- From: *** Hendrickson
- Re: make i:j equivalent to [(k,k=i,j)]?
- Prev by Date: Re: Bus error/ segmentation fault--help?
- Next by Date: Re: make i:j equivalent to [(k,k=i,j)]?
- Previous by thread: Re: Bus error/ segmentation fault--help?
- Next by thread: Re: make i:j equivalent to [(k,k=i,j)]?
- Index(es):