Make Cortana Stop Kicking Me!!!???

This is a discussion on Make Cortana Stop Kicking Me!!!??? within the C++ Programming forums, part of the General Programming Boards category; Um... sorry bout the title, but this is ........ing me off... I've been working on debugging this software, which I ...

  1. #1
    Student drdroid's Avatar
    Join Date
    Feb 2002
    Location
    Montreal, Quebec
    Posts
    669

    Question Make Cortana Stop Kicking Me!!!???

    Um... sorry bout the title, but this is ........ing me off... I've been working on debugging this software, which I proudly call Cortana, and it's always stuck in a loop. Can you help me here? If you find anything small along the line, can you just tell me about that also? All help is needed.
    Last edited by drdroid; 03-01-2003 at 08:34 PM.

  2. #2
    xmdvp
    Guest
    hi

    your program gets stuck in cortana::find_line() because you forgot to do a break when str is the empty string:

    Code:
    		else if(str=="")
    		{
    			prep=false;
    			cortana::find_responce();
    			break;
    		}
    because if you don't break you are going to loop forever because you don't increase linenumber.

    BTW: that's the reason why you should use a proper for() statement whenever you can and leave the while() for things that don't have a known limit

  3. #3
    End Of Line Hammer's Avatar
    Join Date
    Apr 2002
    Posts
    6,231
    What debugging have you done? Where do you think the loop is?

    What's this:
    >>mainlp=1;
    >>while(mainlp!=0)
    Where does mainlp get changed to 0?

    [edit]
    >>ifstream check_in("compare.txt");
    You didn't check the open worked.
    When all else fails, read the instructions.
    If you're posting code, use code tags: [code] /* insert code here */ [/code]

  4. #4
    xmdvp
    Guest
    did you read my post ?

  5. #5
    drondiffcomp
    Guest

    rply:

    this is me drdroid, on another computer, yah hammer, I did error checking but i deleted most of it as I went through. i'm going to go try the break thing. Oh, and the mainlp thing, that's supposed to loop as you continue to put in information. You have to exit out for it to stop.

  6. #6
    Student drdroid's Avatar
    Join Date
    Feb 2002
    Location
    Montreal, Quebec
    Posts
    669

    Question rply:

    ok so i put in the breaks... so why do i have multiple responces and multiple lines.... the program seems to be checking every word and givving me a responce to each on different strings... this is mind boggling. I'm checking into it... anybody know why?

    edit: it only makes sure that one of the words is right, instead of both out of the sentence.
    Last edited by drdroid; 02-27-2003 at 04:40 PM.

  7. #7
    drondiffcomp
    Guest

    Talking

    anybody? ::bump::

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. trying to make a KenGen ( for a game tool )
    By lonewolfy in forum C# Programming
    Replies: 4
    Last Post: 03-28-2007, 09:23 AM
  2. Why does my prog just stop?
    By Queatrix in forum Windows Programming
    Replies: 4
    Last Post: 03-01-2006, 05:12 PM
  3. Win32 Common Controls in C++, how do i make and use them?
    By C+noob in forum Windows Programming
    Replies: 6
    Last Post: 01-09-2006, 11:53 AM
  4. want to make this small program...
    By psycho88 in forum C++ Programming
    Replies: 8
    Last Post: 11-30-2005, 02:05 AM
  5. Make it stop!
    By dougaerb in forum C++ Programming
    Replies: 2
    Last Post: 10-31-2001, 11:04 PM

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