You just did it. There isn't any equivalent, so you have to do it with conditionals, like you just showed. Instead of ??? you can use a comment, or you can invert the logic and leave off the else part.
Tracy Dryden
Meddle not in the affairs of dragons,
For you are crunchy, and good with mustard.
Exit For won't continue the loop, it will end it. That's not what the OP is looking for. They want a command that will skip the rest of the stuff inside the for loop and go back to the top of the loop. There is no syntactical reason to have such a command, you can easily do without it just as the OP demonstrated above. It's just for convenience. I'm surprised Java even has such a command, since it is otherwise such a strict language, and that kind of command violates a major precept of structured programming - one entry, one exit.
Tracy Dryden
Meddle not in the affairs of dragons,
For you are crunchy, and good with mustard.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.