Thread: Little Help

  1. #16
    Registered User
    Join Date
    Oct 2012
    My while loop is messed up too, trying to figure out how I can set it up logically and not getting anywhere

  2. #17
    Registered User
    Join Date
    Sep 2006
    Why not use the intuitive for loop as I showed you? When you have a CERTAIN number you need to stop at, a for loop is just the clearer choice. When you have an unknown number of loops to make, then a while loop seems quite natural, and a better choice.

  3. #18
    Algorithm Dissector iMalc's Avatar
    Join Date
    Dec 2005
    New Zealand
    This line wont do what you think:
    printf("//|   |\\   |\n");
    Backslash is the escape character, which is used for things such as \n to do a newline etc.
    This means the above gives you one backslash, not two. You'll want to use this to get two backslashes:
    printf("//|   |\\\\   |\n");
    My homepage
    Advice: Take only as directed - If symptoms persist, please see your debugger

    Linus Torvalds: "But it clearly is the only right way. The fact that everybody else does it some other way only means that they are wrong"

Popular pages Recent additions subscribe to a feed