Color and goto

This is a discussion on Color and goto within the C Programming forums, part of the General Programming Boards category; How do I change the text color in a C program that runs in DOS? And How do I use ...

  1. #1
    Registered User
    Join Date
    Nov 2002
    Posts
    1

    Post Color and goto

    How do I change the text color in a C program that runs in DOS?

    And

    How do I use goto's in C

    Thanks,

    Patrick Blochle

  2. #2
    FCF
    FCF is offline
    Registered User FCF's Avatar
    Join Date
    Dec 2001
    Posts
    40
    For the text color Q, i saw this Q in other post in this site, a search should help.

    For the goto Q, i don't know the rest but i read from somewhere, saying that goto should not be used. This is unstructured programming.

    Can't help, sorry..

  3. #3
    ~- Y u n a -~ beely's Avatar
    Join Date
    Dec 2001
    Posts
    291
    Originally posted by FCF


    For the goto Q, i don't know the rest but i read from somewhere, saying that goto should not be used. This is unstructured programming.

    Can't help, sorry..
    for my guess (i dont know whether this is true)

    you know there's a number beside that you can enter the code on the pad? well for eg:

    001 | #include <stdio.h>
    002 | ....
    003 | ....
    004 | ....
    005 | ...
    006 | ....
    007 | goto (006);

    that mean it will loop and run the statement of code which is located at 006.


    or ...

    you need to set the definition :

    #include <stdio.h>
    ..
    ..
    ..
    start;
    ..
    ..
    ..
    goto (start);
    ..
    ..

  4. #4
    Registered User Inept Pig's Avatar
    Join Date
    Apr 2002
    Posts
    140
    Money frees you from doing things you dislike. Since I dislike doing nearly everything, money is handy - Groucho Marx

  5. #5
    End Of Line Hammer's Avatar
    Join Date
    Apr 2002
    Posts
    6,231
    >>How do I use goto's in C
    If you don't know how to, then you most certainly don't need to. Use another method to control your program flow.
    When all else fails, read the instructions.
    If you're posting code, use code tags: [code] /* insert code here */ [/code]

Popular pages Recent additions subscribe to a feed

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21