Search:

Type: Posts; User: howhy

Search: Search took 0.01 seconds.

  1. Thread: map of maps ??

    by howhy
    Replies
    1
    Views
    1,077

    map of maps ??

    in case of single map, to see whether a key exists or not mapname.count(keytofind) is used


    map<int,bool>rb;
    map<int,bool>::iterator rb_it;

    rb.insert(make_pair(5,true));...
  2. Replies
    1
    Views
    2,744

    how to implement SPARSE graph in c/c++?

    i want to implement sparse graph in c\c++.

    i need help regarding it.
    is there any builtin sparse graph in STL?
    or any kind of help that STL can provide regarding this?

    any help will be...
  3. lydiapeter says No, there is no way to do...

    lydiapeter says


    No, there is no way to do that....
    when dynamically allocating memory, default ctor will be called for each object.

    Yes, there is a way to do what u require..
    that is...
  4. myclass *obj=new myclass[5]; when dynamicaly...

    myclass *obj=new myclass[5];

    when dynamicaly allocating memory for an array of objects,
    default ctor will be called for each object.

    there is no way to call another ctors.
    because other...
  5. i got it......................

    i got it......................
  6. try to understand what i mean........ ok, i am...

    try to understand what i mean........

    ok, i am rephrasing my question...



    typedef struct temp
    {
    int data;
    }T;
  7. laserlight i know there are uses of pointer to...

    laserlight

    i know there are uses of pointer to pointer, but i mean specially here where the purpose is solved by just pointer.


    my question is
    when i am calling setframe3(tp);
    and then...
  8. My question is what is the use of pointer to...

    My question is

    what is the use of pointer to pointer ,if purpose is solved by just a pointer???

    like


    when i call setframe2(&tp); i am passing address of pointer

    void setframe2( T...
  9. Should i pass address of pointer or just pointer???

    Firstly see the code:

    #include<iostream>
    #include<conio.h>
    using namespace std;

    typedef struct temp
    {
    int data;
    } T;
  10. Replies
    12
    Views
    11,590

    Salem done, but no difference in output. ...

    Salem

    done, but no difference in output.



    i think c++ will close the outfile automatically when the dtor will be called.
    any way i tried it, but no difference in output.
  11. Replies
    12
    Views
    11,590

    Latest Code: #include...

    Latest Code:

    #include<iostream>
    #include<fstream>
    #include<conio.h>

    void main()
    {
    char ch;
  12. Replies
    12
    Views
    11,590

    Salem says yeah, that was imp, thanks for...

    Salem says

    yeah, that was imp,
    thanks for reminding.

    salem

    i checked it, it does not matter.
  13. Replies
    4
    Views
    1,352

    well, this is very imp info regarding memory...

    well,

    this is very imp info regarding memory leaks.

    thanks for this.

    and keep it up.
  14. Replies
    12
    Views
    11,590

    new lines of code added in bold void...

    new lines of code added in bold


    void main()
    {
    ...................
    .................
    ................
    ..................
  15. Replies
    12
    Views
    11,590

    !outfile.is_open() tried same ouput ...

    !outfile.is_open() tried

    same ouput





    ???????????????
  16. Replies
    12
    Views
    11,590

    OUTPUT TO PRINTER using c++ ???

    This is my program for printing a file using c++ program.
    This gets complied and linked properly.
    but when i run it , then it does not print anything.

    its OUTPUT

    Input file opened
    OUTPUT...
  17. Replies
    5
    Views
    2,819

    Ken Fitlike says Another option is to use an...

    Ken Fitlike says
    Another option is to use an unnamed namespace.


    well,
    this is my code, it is working fine with static.
    but i would like to know how to do it using unnamed namespace.
  18. Replies
    5
    Views
    2,819

    Thanks :-)

    Thanks Salem :-)

    Actually i knew abt this fact of static.
    but still , i was not sure.
    and i just wanted to confirm.

    soooo....

    thanks again.
  19. Replies
    5
    Views
    2,819

    variable in file scope ???

    how to make a variable in file scope.

    I mean
    it should not be local to a function.
    and it should not be global ( available to other source files).

    it should be availble only in the current...
Results 1 to 19 of 19