Search:

Type: Posts; User: tunerfreak

Page 1 of 2 1 2

Search: Search took 0.00 seconds.

  1. Replies
    6
    Views
    1,150

    so it should look like this while(inFile >> ...

    so it should look like this


    while(inFile >> V.name && V.name != "#")

    now that i think about it, it dont make sense the way i originally had it. man i hate dealing with files

    and u...
  2. Replies
    6
    Views
    1,150

    i changed the while loop to look like this ...

    i changed the while loop to look like this


    while(inFile >> V.name != "#")
    {
    cout << "hi3" << endl;
    }

    and i get an infinate on hi3
  3. Replies
    6
    Views
    1,150

    ok when i do that i get an infinite look right...

    ok when i do that i get an infinite look right there, y?
  4. Replies
    6
    Views
    1,150

    reading from a text file queation

    i want to read stuff in a text file one line at a time by line because i have to store the first thing in each line in a list the first time though, close the file reopen it again to get back to the...
  5. Replies
    5
    Views
    6,117

    i added the const and the errors went away but we...

    i added the const and the errors went away but we will see if anything else arises with me doing that.
  6. Replies
    5
    Views
    6,117

    error help making no sense

    i am creating a graph from a file and i am getting 2 errors saying that i dont have a copy constructor in struct Edge and struct Vertex but i clearly do. it came up when i was doing my io function at...
  7. Replies
    14
    Views
    4,111

    isn this allocating mem for it??? that part was...

    isn this allocating mem for it??? that part was given by teacher so i just assumed it was


    Key(char* data) { this->data = new char[strlen(data)];
    strcpy(this->data,data);}
  8. Replies
    14
    Views
    4,111

    k i fixed that but it didnt fix the problem though

    k i fixed that but it didnt fix the problem though
  9. Replies
    14
    Views
    4,111

    ok so i narrowed it down to my loadFile function...

    ok so i narrowed it down to my loadFile function wher i read the file in


    void BST::loadFile()
    {
    Key key;
    cout << "Enter the the file location" << endl;
    cin >> inFileName;...
  10. Replies
    14
    Views
    4,111

    k got rid of thoes errors but it still crashes

    k got rid of thoes errors but it still crashes
  11. Replies
    14
    Views
    4,111

    ur right i missed that thx. but no that didnt fix...

    ur right i missed that thx. but no that didnt fix it im positive its mostly my insert function cause when i take it out and just read the file then print it it prints out all the names but then...
  12. Replies
    14
    Views
    4,111

    need help program crashing

    i am trying to make a Binary Search tree and my program is crashing when i try to insert names from a file into the tree and i cant figure out y. my load file function works if i just read in the...
  13. Replies
    7
    Views
    1,142

    ok just an update now i got it to loop through...

    ok just an update now

    i got it to loop through the players but now i cant get it out of the first while loop after all the players have gone so that i can print who won the game


    int g = 0;...
  14. Replies
    7
    Views
    1,142

    breaking out of a loop

    forget about my other question now.

    ok simple question i would think but i cant get it to work right. i have this loop


    while(1)
    {
    do
    {
    player = p.getPlayer(k);
  15. Replies
    7
    Views
    1,142

    DECKS is a constant of 8 also its random so i get...

    DECKS is a constant of 8 also its random so i get a shuffled deck of cards
  16. Replies
    7
    Views
    1,142

    that helped a little but my card class creates...

    that helped a little but my card class creates the card so i cant really go card.suit orcard.num. i randomise the cards face and suit i think its more of an if statement what im having trouble with...
  17. Replies
    7
    Views
    1,142

    help with loop

    im trying to write a loop so that 8 of each card in a blackjack game is made and i cant get it to work right. it should print out 8 cards for each card made and delete the card if there are already...
  18. Replies
    10
    Views
    1,307

    well i figured it out but list* hand does...

    well i figured it out but list<Card>* hand does need to be a pointer it does not like it otherwise.

    but here is what i came up with to print list


    void Player::printHand()
    {

    ...
  19. Replies
    10
    Views
    1,307

    no i know what the error means but the printHnad...

    no i know what the error means but the printHnad is suppose to print the players hand, card dont control that all that print() in the card class does is print what kind of card it is
  20. Replies
    10
    Views
    1,307

    ok then i will get an error saying that my print...

    ok then i will get an error saying that my print hand function is not a member of Card
  21. Replies
    10
    Views
    1,307

    sorry i didnt copy down far enought.. i did loop...

    sorry i didnt copy down far enought.. i did loop through the players hand though


    for(iter = hand.begin(); iter != hand.end(); ++iter)
    {
    iter->printHand();
    }
    but i also get errors in...
  22. Replies
    10
    Views
    1,307

    Why is my list not being created?

    im trying to make a blackjack game using stacks and lists and i am having a problem with my lists, its not being created and i dont know y? the list is a list of cards for the players and the stack...
  23. Replies
    7
    Views
    913

    so it should be something like ...

    so it should be something like


    if(!array[currentDepth][currentRow][currentCol].getMarked())

    or something along that order.

    EDIT:

    yup thats it, i just threw that in there and it worked...
  24. Replies
    7
    Views
    913

    so after a little testing i found out that what i...

    so after a little testing i found out that what i really did there was stop printing if a player has won although it dont work perfectly though so now i dont know how to stop it from printing if...
  25. Replies
    7
    Views
    913

    u mean array[d][r][c].getMarked ? im not marking...

    u mean array[d][r][c].getMarked ? im not marking with that its just checking of the cell im in is marked by a player. i mark with array[currentDepth][currentRow][currentCol].mark(player)
Results 1 to 25 of 45
Page 1 of 2 1 2