Search:

Type: Posts; User: noobcpp

Page 1 of 9 1 2 3 4

Search: Search took 0.01 seconds.

  1. Replies
    13
    Views
    11,740

    LOL don't take it offensive.Think practically. I...

    LOL don't take it offensive.Think practically. I need to solution quickly.sometimes c-board takes time and sometime gamedev.net takes time. so I've posted in both of them.
    and I've never said your...
  2. Replies
    13
    Views
    11,740

    I think I've found the problem LessFunctor is...

    I think I've found the problem LessFunctor is designed in such a way that more than one element can get equal weight. But its not a multimap.
    and Ya I just made sure that KeyT doesn't need an...
  3. Replies
    13
    Views
    11,740

    at the end I wrote the stl code that is ...

    at the end I wrote the stl code that is
    _M_impl._M_key_compare(__k,_S_key(__j._M_node))which actually is
    _Rb_tree_impl<_Compare>::_Key_compare(__k,_S_key(__j._M_node)) and that means...
  4. Replies
    13
    Views
    11,740

    I don't need any kinda ordering in the map (I...

    I don't need any kinda ordering in the map (I know you would say me to use unordered_map). so I did it always returns true.
    thats why I named it FakeLess However I've another LessFunctor that I can...
  5. Replies
    13
    Views
    11,740

    std::map::find() crashing

    In one of my code std::map::find() is crashing the programm.
    actually I am using map<ConstructPointer, QStringList*>;
    My ConstructPointer contains and constructed by two data members of integer...
  6. Replies
    8
    Views
    1,161

    Thanks all understood I forgot that std::vector...

    Thanks all understood
    I forgot that std::vector does not name a type rather std::vector<SOMETYPE> is a Typename (Silly mistake)
  7. Replies
    8
    Views
    1,161

    One template question

    template <typename T, typename CONT /*= std::vector*/ >
    struct Stack{
    CONT elem;
    };
    The above code compiles fine as it should be If I just uncomment the std::vector one it fires compilation...
  8. Replies
    24
    Views
    7,334

    Ya I've already done it and it gives the same...

    Ya I've already done it and it gives the same result no change.
    Well this is my current code.

    #include <stdio.h>
    #include <stdlib.h>
    #include <string.h>

    struct StudentInfo{
    //char* name;...
  9. Replies
    24
    Views
    7,334

    Currently there is no short in my code I've...

    Currently there is no short in my code I've changed all of them to normal int
  10. Replies
    24
    Views
    7,334

    You can assume something like this.I was showing...

    You can assume something like this.I was showing some of my friends about when we might need to use realloc. suddenly I got stuck and more than 8 hours past still trying to find the answer. I must...
  11. Replies
    24
    Views
    7,334

    I am confused What would I write to solve this...

    I am confused What would I write to solve this problem ??
  12. Replies
    24
    Views
    7,334

    But I've already wrote scanf("%d\n", &s); in my...

    But I've already wrote scanf("%d\n", &s); in my code @ Line 9

    ----------- EDIT ---------

    did you mean this ??

    printf("Enter Roll of Student %d :\t", i);
    //fflush(stdin);
    int...
  13. Replies
    24
    Views
    7,334

    tried just now do{ //StudentInfo.name...

    tried just now
    do{
    //StudentInfo.name removed

    printf("Enter Roll of Student &#37;d :\t", i);
    //fflush(stdin);
    scanf("%d", &(students[i].roll));
    printf("\n\nEnter another ? (1/0):\t");...
  14. Replies
    24
    Views
    7,334

    Well this is my current code do{...

    Well this is my current code
    do{
    printf("Enter Roll of Student %d :\t", i);
    fflush(stdin);
    scanf("%d", &(students[i].roll));
    printf("\n\nEnter another ? (1/0):\t");
    fflush(stdin);...
  15. Replies
    24
    Views
    7,334

    Hmm after I did StdInfo* students; I also did...

    Hmm after I did

    StdInfo* students;
    I also did

    students = malloc( size*sizeof(StdInfo) );
    initially storage for teh Object is also allocated.
    I am doing
    students = realloc( students,...
  16. Replies
    24
    Views
    7,334

    realloc segfaults.

    #include <stdio.h>
    #include <stdlib.h>
    #include <string.h>

    struct StudentInfo{
    unsigned int roll;
    };

    typedef struct StudentInfo StdInfo;
  17. One solution probabbly can do coertion If I've ...

    One solution probabbly can do coertion
    If I've

    operator std::auto_ptr<Class>(){
    return std::auto_ptr<Class>(this);
    }

    But is this solution recomendable ??

    and if all my functions take...
  18. But using smart pointers increases syntactic...

    But using smart pointers increases syntactic complexity.
    even if I design a macro for general pointer to auto_ptr you still have to type the macro name.
    its not an automatic job.
  19. Now I am using. Js::JType* x = new Js::JType;...

    Now I am using.

    Js::JType* x = new Js::JType;
    list.insert(make_pair(key, x));
    return list[key];

    It fixes the problem and I think its might raise a null pointer issue which is not going to...
  20. invoking Base::virtualMethod() instead of Derived

    In my class Js::Object I've an operator() overload which returns Js::JType*
    all Other Classes in Js Namespace e.g. Js::Number, Js::String etc.. even Js::Object inherits from Js::JType

    ...
  21. Replies
    15
    Views
    2,735

    Ok I think these few Lines of Code will explore...

    Ok I think these few Lines of Code will explore What I am trying to do.


    Js::Array ex;
    ex += Js::Number(2);
    ex += Js::String("Hello");
    ex += "Hello World"
    ex += 20;

    += is a testing...
  22. Replies
    15
    Views
    2,735

    I dont expect a link against literal 5 but not...

    I dont expect a link against literal 5
    but not only literals require const X& during += operator overload
    But If somebody does like.

    const X& y = SOMETHING;
    Example ex;
    ex += y;

    then...
  23. Replies
    15
    Views
    2,735

    But If I code like this a different problem will...

    But If I code like this a different problem will appear if I do this. although the problem is not so critical or important.

    it is when a pointer is supplied its the vector content is linked with...
  24. Replies
    15
    Views
    2,735

    so any based on Linux kernal 2.6+ , Mac, windowx...

    so any based on Linux kernal 2.6+ , Mac, windowx Xp+ offers this features ??
  25. Replies
    15
    Views
    2,735

    Ya I now that. However one thing I would like...

    Ya I now that.

    However one thing I would like to make sure

    when an application exists does all Operating System cleans the garbage memory(e.g. new Objects on which delete has not been used)...
Results 1 to 25 of 221
Page 1 of 9 1 2 3 4