Search:

Type: Posts; User: skanxalot

Page 1 of 2 1 2

Search: Search took 0.01 seconds.

  1. Help with CString class and operator+ overloading

    Could someone help me with operator overloading and my String class. I'm stuck with the '+' operator, which should "return a new object of type CString that contains the contents of 'this' Cstring...
  2. Ah, forget about it. I got it working. Thanks...

    Ah, forget about it. I got it working. Thanks for offering though.
  3. Its my own class, here's how it looks: ...

    Its my own class, here's how it looks:



    class CString
    {

    friend class CStringIterator;

    public:
  4. Please help with String class, returning strings

    I'm desperate here, please be gracious. I just don't know what to do with this CStringIterator class function that returns the current word in a string.

    Here's main:


    void main()
    {
    int...
  5. Replies
    13
    Views
    1,364

    here ya go.

    here ya go.
  6. Replies
    13
    Views
    1,364

    I need some more help with this program, ...

    I need some more help with this program,


    from main...


    BST Original;

    Original.Insert (X);
    Original.Insert (Y);
  7. Replies
    13
    Views
    1,364

    Should I also have done "*P->Left = NULL"? ...

    Should I also have done "*P->Left = NULL"? (notice the *)
  8. Replies
    13
    Views
    1,364

    Thanks for the help, that fixed it. But I'm not...

    Thanks for the help, that fixed it. But I'm not sure what you mean here:

    ---------------------------------------------------------------------------------
    You also have some memory leaks...

    ...
  9. Replies
    13
    Views
    1,364

    Thanks for the replies, here's all the code.

    Thanks for the replies, here's all the code.
  10. Replies
    13
    Views
    1,364

    Please help with BST

    I'm working on a BST for the first time and need some big time help. I've gotten some of the functionality written and was wanting to test it so I've got this simple code that Inserts a node into...
  11. Replies
    11
    Views
    2,611

    Forget it, I just found it. I was using...

    Forget it, I just found it. I was using namespace std in .h file, not in .cpp file. Thanks for trying to help.
  12. Replies
    11
    Views
    2,611

    I didn't think so. The header/impl files compile...

    I didn't think so. The header/impl files compile fine with the exception included but the app file goes to crap. When I take the exception class out, the app compiles fine. What's the deal?
  13. Replies
    11
    Views
    2,611

    When I add an exception in the...

    When I add an exception in the header/implementation file, what do I have to change in the application file?
  14. Replies
    11
    Views
    2,611

    That didn't change anything. I had the null...

    That didn't change anything. I had the null commented out when I compiled.
  15. Replies
    11
    Views
    2,611

    The null was just a space holder from earlier,...

    The null was just a space holder from earlier, don't worry about it.

    As far as the errors, here's an ex.:
    c:\Program Files\Microsoft Visual Studio .NET\Vc7\include\streamb.h(90): error C2872:...
  16. Replies
    11
    Views
    2,611

    Exceptions. (This should be easy)

    I want to have an exception for my stack class that is thrown if new memory cannot be allocated for a push. From my book, I entered the following into my program:



    #include <exception>...
  17. Cheers mate! :D

    Cheers mate! :D
  18. I want to delete all of the nodes on the stack. ...

    I want to delete all of the nodes on the stack. Here's the header file I use with it:



    typedef int StackType;

    class Stack
    {
    public:
    Stack();
  19. Can someone find the error in this destructor?

    I don't know what's going on here, but its going to crap everytime. I'm just trying to clear all the memory like a good programmer.



    #include "stack.h"
    #include <cstddef>

    Stack::Stack()
    {...
  20. Replies
    4
    Views
    1,693

    Cheers, mate! :D

    Cheers, mate! :D
  21. Replies
    4
    Views
    1,693

    OK, you're reply didn't make much sense to me as...

    OK, you're reply didn't make much sense to me as I think I'm quite a bit behind you. I've just been learning recursion for a week now. This is what I know:

    To find the binary of a decimal you do...
  22. Replies
    4
    Views
    1,693

    Decimal to binary recursively?

    I'm stuck. Can somebody help me with the algorithm to convert a decimal integer (0 - 1,000,000,000) to binary recursively? I know I'm going to %2 until it equals 0 or 1, but then what do I do?
  23. Replies
    2
    Views
    961

    Thanks!

    Thanks!
  24. Replies
    2
    Views
    961

    getline help!

    I have this function for my address book program but the first getline isn't working, somebody please tell me why!



    void ChangeEntry (sturec &book, fstream myfile, int &recordnum)
    {
    int...
  25. Replies
    2
    Views
    3,819

    incompatible types huh??

    I'm getting a compiler error and was hoping someone could help me out. This is what I'm trying:

    char identity[7];

    string id = ("id") // from the form, this is a CGI program

    identity =...
Results 1 to 25 of 37
Page 1 of 2 1 2