Thread: Goto statements, good or bad?

  1. #16
    use FUNCTIONS!

  2. #17
    &TH of undefined behavior Fordy's Avatar
    Join Date
    Aug 2001
    Originally posted by biosx
    IMHO, if you can't program without goto's, then you can't program. Not to be harsh, but procedural programming should be structured. goto's violate structured programming. I should be able to look at a flowchart of your program and be able to trace a line from beginning to end without having to lift my pencil.

    goto's are probably the lamest thing on the planet. continue's are up in the top 10.
    Your missing the point.....its not a messure of ability or even preference........occasionally goto will have its uses.....otherwise it would be taken out of the standard.......

  3. #18
    Super Moderator VirtualAce's Avatar
    Join Date
    Aug 2001
    In short, goto is fine in assembly and needed. JMPs are essentially gotos. In C/C++, there is always a better way.

  4. #19
    Originally posted by biosx

    goto's are probably the lamest thing on the planet. continue's are up in the top 10.
    In 18 months of programming, I've never found a use for continue. i know 18 months isn't long but I thought I might have used it by now.

    Btw, I've never used goto either

  5. #20
    I'm Back
    Join Date
    Dec 2001
    I think this whole qestion on to GOTO or not to GOTO is dumb

    I totally agree with

    Fordy- goto has its occ uses
    Bubba- the whole thing he said

    Again i'll repeat.. that the UNREG guy said to use while in the case ESPARNO asked but as you said that DO executes and then chks i suggest that it will be better to use it than while

    Also, i think a lot of people just say that gotos shouldn't be used blah blah blah.. to sound but i have used GOTOs 1000's of times and not encounterd a single problem yet.

  6. #21
    Intranasal Heroin User Xterria's Avatar
    Join Date
    Sep 2001
    Buffalo, NY


    gotos are needed when you have just typed thousands of lines and you realize you need to repeat somthing

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Typecasting -- Good or Bad
    By Roaring_Tiger in forum C Programming
    Replies: 6
    Last Post: 01-21-2006, 04:41 PM
  2. Need some help with a basic tic tac toe game
    By darkshadow in forum C Programming
    Replies: 1
    Last Post: 05-12-2002, 04:21 PM
  3. How do i use Goto?
    By Unregistered in forum C++ Programming
    Replies: 18
    Last Post: 01-06-2002, 10:38 AM
  4. but why not GOTO?
    By LonelyPlanetWanderer in forum C Programming
    Replies: 13
    Last Post: 12-24-2001, 11:46 AM
  5. good news and bad news
    By Garfield in forum A Brief History of
    Replies: 25
    Last Post: 10-27-2001, 07:31 AM