Search:

Type: Posts; User: Doodle77

Page 1 of 3 1 2 3

Search: Search took 0.01 seconds.

  1. Replies
    11
    Views
    5,711

    Don't try to hijack threads, don't break forum...

    Don't try to hijack threads, don't break forum rules.
    http://cboard.cprogramming.com/c-programming/announcement-forum-guidelines-read-before-posting.html...
  2. Replies
    8
    Views
    1,427

    You could run Turbo C in DOSBox...

    You could run Turbo C in DOSBox
  3. Thread: Your C++ IDE

    by Doodle77
    Replies
    25
    Views
    13,554

    SciTE + gcc/friends on both Windows and Linux.

    SciTE + gcc/friends on both Windows and Linux.
  4. answer = playAgain(2); //LINE 195 while...

    answer = playAgain(2); //LINE 195
    while (turnAgain == 'y'); //LINE 196
    {
    // roll again
    makePlay();
    printf("Die 1 is a %d.\n", die1);
    printf("Die 2 is a...
  5. Replies
    12
    Views
    1,684

    A local copy of ptr is passed to sayHi, if you...

    A local copy of ptr is passed to sayHi, if you want to modify the value of ptr in main, you need to pass a pointer to ptr, so you would have void sayHi(char **str).

    jason_m: you're thinking of the...
  6. Replies
    213
    Views
    83,092

    The C implementation and C++ implementation of...

    The C implementation and C++ implementation of those tests are different code, they work differently. If you compiled the C example with g++ instead of gcc it would come out exactly the same.
  7. Replies
    3
    Views
    7,871

    IActiveDesktop::ApplyChanges...

    IActiveDesktop::ApplyChanges, if you can use it from C#
  8. Replies
    3
    Views
    1,440

    Logfile now says: Called function: 00000065...

    Logfile now says: Called function: 00000065 (that's what it claims, but the call works fine, and calls a function somewhere near 0x7000000 i think)
    The library with the function is based somewhere...
  9. Replies
    3
    Views
    1,440

    Getting around a compiler error

    I really need to print what the address of a certain member function is, but the compiler is complaining, saying
    "error: ISO C++ forbids taking the address of a bound member function to form a...
  10. Replies
    4
    Views
    1,294

    You're completely out of memory. Assuming your...

    You're completely out of memory. Assuming your struct is 8 bytes long, you will need 488281.25 megabytes of memory for the whole linked list. That is probably even larger than your hard drive.
  11. Perhaps the main thread's stack is 1MB?

    Perhaps the main thread's stack is 1MB?
  12. Replies
    2
    Views
    1,486

    On linux you can call x-www-browser which is...

    On linux you can call x-www-browser which is generally a symlink to an available browser, so that you're not reliant on the user having Firefox. There is no cross-platform way to do without using...
  13. Replies
    11
    Views
    2,751

    The operating system would most likely buffer the...

    The operating system would most likely buffer the file for you.
  14. Replies
    11
    Views
    2,751

    If you're afraid one of the "words" will be huge,...

    If you're afraid one of the "words" will be huge, you can have the program move forward until it finds the newline to get the length of the line, then malloc()s that much memory, and then goes back...
  15. Replies
    11
    Views
    2,751

    Use fgets()...

    Use fgets()
  16. Thread: 64kb

    by Doodle77
    Replies
    56
    Views
    12,621

    Compile the C code as C++, and you get exactly...

    Compile the C code as C++, and you get exactly the same result.
  17. Thread: 64kb

    by Doodle77
    Replies
    56
    Views
    12,621

    I'm not trying to say that I could magically...

    I'm not trying to say that I could magically implement everything in STL in less space, I'm just saying that the mere use a string or vector in your c++ program adds 52kb of STL code.
  18. Thread: 64kb

    by Doodle77
    Replies
    56
    Views
    12,621

    #include #include int...

    #include <vector>
    #include <string>

    int main() {
    std::vector<int> v(10);
    for (int i=0;i<10;i++) {
    v[i] = i*(i+i^3);
    }
    reverse(v.begin(), v.end());
    std::string q = "omgomgom";
  19. Thread: 64kb

    by Doodle77
    Replies
    56
    Views
    12,621

    He means this: #include int...

    He means this:

    #include <iostream>

    int main() {
    std::cout << "STL adds bloat. Lots of it.";
    return 0;
    }
    8109
    gcc version 3.4.2 (mingw-special)
  20. Replies
    2
    Views
    1,689

    You could also do typedef struct element...

    You could also do


    typedef struct element element;
    struct element {
    int value;
    element* next;
    };
  21. sscanf...

    sscanf. Use the &#37;f type specifer. Be sure to look at the example.
    I think you can also do it with a stringstream or something but I'm not sure how.
  22. Replies
    9
    Views
    4,670

    http://msdn2.microsoft.com/en-us/library/ms648042(...

    http://msdn2.microsoft.com/en-us/library/ms648042(VS.85).aspx
    http://msdn2.microsoft.com/en-us/library/ms648046(VS.85).aspx
    the resource type you want is RT_RCDATA (application-defined resource)....
  23. Replies
    9
    Views
    4,670

    uh >_> can't find it right now

    uh >_> can't find it right now
  24. Replies
    9
    Views
    4,670

    On windows, you can use resources. Really the...

    On windows, you can use resources. Really the best idea is to just put it in a separate file though.
  25. Replies
    12
    Views
    1,561

    esbo, any particular reason you use the old (i.e....

    esbo, any particular reason you use the old (i.e. pre-C89) function declaration syntax? TurboC?
Results 1 to 25 of 57
Page 1 of 3 1 2 3