is there a way to simply tell the compiler to JUMP back to a different point???

like:

loop;
"stuff"
loop;

the first loop says where the second loop loops back to any help would help thatnks alot

-kbcubs-

Recommended Answers

All 3 Replies

lookup for the keyword goto But using goto for looping is very very bad practice. For looping you can use the for , while , do-while keywords. It is much easier to understand and easier to maintain than goto .

ok thanks wolf pack

-kbcubs-

Why couldn't you split your code into seperate methods and execute a certain method when you need it? As Wolf said, goto is bad practice and I consider it old school :cheesy:

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.