Search:

Type: Posts; User: Jozrael

Search: Search took 0.00 seconds.

  1. Replies
    3
    Views
    1,801

    Quick input check question

    So I want to check to see if the command line argument I received was an integer. How do I do this?


    #include <iostream>
    using namespace std;

    int main(int argc, char* argv[]) {...
  2. Replies
    36
    Views
    4,219

    Edit: Foot in mouth x2?

    Edit: Foot in mouth x2?
  3. Replies
    36
    Views
    4,219

    EDIT: I'm a retard. Fixed. lol.

    EDIT: I'm a retard. Fixed. lol.
  4. Replies
    36
    Views
    4,219

    I'm fairly sure its memory corruption. I have a...

    I'm fairly sure its memory corruption. I have a map of strings and a class called 'page' (i'm simulating a web crawler) and I just found out that none of the info is actually being stored in the map...
  5. Replies
    36
    Views
    4,219

    Sigh heh. Ok, now I'm getting segfaults. My...

    Sigh heh. Ok, now I'm getting segfaults. My intuition (which is often wrong as a novice programmer) tells me that it has to do with the fact that I'm calling this Crawl function from within...
  6. Replies
    36
    Views
    4,219

    What do you prefer to use? is there like an...

    What do you prefer to use? is there like an 'alternate STL'? Or do you just code it all from scratch yourself @_@?
  7. Replies
    36
    Views
    4,219

    Yes it is. I can't even begin to comprehend...

    Yes it is.

    I can't even begin to comprehend the line of code mir posted, haha.

    EDIT: I know about second pages, totally :\.

    Thanks elysia, worked like a charm =).
  8. Replies
    36
    Views
    4,219

    Yes it is. I cant even begin to understand the...

    Yes it is.

    I cant even begin to understand the line of code mir posted, heh.
  9. Replies
    36
    Views
    4,219

    Ah ha, another questions >

    Ah ha, another questions ><. I'm trying to declare another in file stream, and its in a function outside of the main.



    bool Crawl(blah) {
    ...
    for (int i = 0; i < hyperlinks.size();...
  10. Replies
    36
    Views
    4,219

    Oh right, now that you told me how to use it, I...

    Oh right, now that you told me how to use it, I can go back to my old loop. lol

    Thanks guys!
  11. Replies
    36
    Views
    4,219

    Hrm, I'm missing something here. Its probably a...

    Hrm, I'm missing something here. Its probably a preprocessor directive but the ones I'm finding on google arent doing me any good.

    I have:



    string word = "Blah";
    word = tolower(word);
  12. Replies
    36
    Views
    4,219

    Thanks, ' instead of " worked perfectly. ...

    Thanks, ' instead of " worked perfectly.

    Another question ><. How to easily transform strings into lowercase? I hear theres a function StringToLower, but I cant seem to get my program to...
  13. Replies
    36
    Views
    4,219

    Really quick silly question.

    How do I parse a "?

    For example, I'm supposed to be coding a web crawler for this homework, and hyperlinks are enclosed in quotes. How do I do a



    string word;
    //code to fill in word

    if...
  14. Replies
    7
    Views
    1,222

    Well, I found an odd workaround to the problem,...

    Well, I found an odd workaround to the problem, but I'm still not sure why it didn't work in the first place =\. I'll post it later (once I've met the deadline) so I can find out what I was doing...
  15. Replies
    7
    Views
    1,222

    No, we're only allowed to use classes in this...

    No, we're only allowed to use classes in this course. And this is how I setup my program.

    As to the segfault, I found some interesting information via some debugging cout statements...my memory...
  16. Replies
    7
    Views
    1,222

    Alright, well, I 'solved' the first problem by...

    Alright, well, I 'solved' the first problem by throwing a whole series of classes into the equation. It works fine, except for the fact that I'm getting a segfault while running my program (its...
  17. Replies
    7
    Views
    1,222

    Homework Question (New one)

    First problem fixed, segfault problem below.





    <Ignore>Ok, so for my assignment, I need a list of list of list of ints. We're working with lists this week, so more elegant data structures...
  18. Replies
    7
    Views
    1,133

    Alright, I'm much clearer about why I shouldn't...

    Alright, I'm much clearer about why I shouldn't have 'using blah' in my header files, thank you for your help.

    I was confusing the #include and the using for the vector, thank you. I'm just...
  19. Replies
    7
    Views
    1,133

    Thanks for your reply. 1: I prefer to name...

    Thanks for your reply.

    1: I prefer to name classes with capitals, but they provided a main.cpp file for us to use, and it used constructors named 'user', so I went with it. Thanks for the tip...
  20. Replies
    7
    Views
    1,133

    But I want a vector of ads, a specific class I've...

    But I want a vector of ads, a specific class I've declared in another .h and .cpp file. Thank you for your response, if I can give you any more information to help you, please tell me.
  21. Replies
    7
    Views
    1,133

    Homework question

    g++ main.cpp user.cpp ad.cpp
    user.h:29: error: ISO C++ forbids declaration of 'vector' with no type
    user.h:29: error: expected ';' before '<' token

    Here is my user.h file:

    #ifndef _user_h_...
Results 1 to 21 of 21