Anthony Stone wrote:
> I have a program in which I use the structure
>
> go to (101,102,103,104,105,106,107,108,109,110), index
> 110 stuff
> ...
> 109 more stuff
> ...
> 108 and so on
> ...
> ...
>
>
> The computed GOTO used here is an obsolescent feature, but there
> doesn't seem to be an obvious replacement. A CASE construct isn't
> suitable, because there is no jump out at the end of each block --
If your problem is sufficiently regular, how about something along these lines
do i=index,1,-1
select case(i)
case (10)
.. stuff
case (9)
... more stuff
...
end select
end do
Keith Refson
--
Dr Keith Refson,
Building R3
Rutherford Appleton Laboratory
Chilton
Didcot kr AT isise
Oxfordshire OX11 0QX DOT nd DOT rl DOT ac DOT uk
|