Re: dumb question #1 re: DO loops



Thanks to both of you for the rapid responses.

Regarding language choices: I am a pragmatist rather than "religious",
and although Fortran was the first language I learned long ago, I
confess to a preference for C. HOWEVER in this case, unfortunately,
the translation IS necessary and not a "lifestyle choice".

Do you have a recommended URL for a Fortran manual? I did check a few
websites before posting this question but didn't find what I was
looking for.

On Thu, 29 Dec 2005 14:58:15 +0100, "Jugoslav Dujic"
<jdujic@xxxxxxxxx> wrote:

>StevO wrote:
>| I am an long-time C programmer converting an old Fortran program to C.
>|
>| Given the following construct:
>|
>| DO 370 J=1,100
>| IF(ID(J).LT.0) GOTO 370
>| c (some other code here)
>| 370 CONTINUE
>|
>| What does GOTO 370 do? Does it simply skip the "some other code here"
>| section and continue with the next loop iteration (like a C "continue"
>| statement within a C for() loop)? Or does it exit the loop?
>
>The former ("continue") -- the end-label-line is part of the loop.

.


Quantcast