Search:

Type: Posts; User: iMalc

Page 1 of 20 1 2 3 4

Search: Search took 0.07 seconds.

  1. Thread: My Absense

    by iMalc
    Replies
    7
    Views
    5,216

    My Absense

    Hi all, especially those that remember me.
    If you've been wondering where I went, basically I became a dad, and then priorities changed, then my marriage fell apart.

    I used to post here...
  2. Replies
    1
    Views
    2,994

    No, there are two types of rotation,...

    No, there are two types of rotation, left-rotation and right-rotation.
    First build a random tree, then test out your code that performs rotations.
    Once that works, here's an idea:
    At each node......
  3. Replies
    8
    Views
    4,826

    In all honesty, you should never build xml like...

    In all honesty, you should never build xml like that. Always use an XML library.
    I've seen far too many bugs caused by people stringing bits of text together and creating broken XML.
  4. Replies
    9
    Views
    3,578

    Oh, missed one other case above... Does the...

    Oh, missed one other case above...
    Does the class prevent copy-construction & assignment, and move variants of these? Yes => Use vector of unique_ptrs.
  5. Replies
    9
    Views
    3,578

    There should be a flowchart for this... To...

    There should be a flowchart for this...

    To decide which option to use for storing items in a vector:
    Are the object lifetimes greater than the vector itself and the objects lifetimes are entirely...
  6. Replies
    6
    Views
    1,256

    Don't do this. Header includes that have ...

    Don't do this.
    Header includes that have <> instead of "" tell the compiler to look first in the locations where system header files are.
    You should leave the code alone.
  7. Replies
    3
    Views
    3,149

    When using memset for explicitly just one byte,...

    When using memset for explicitly just one byte, the difference is that using a plain old assignment statement is both shorter to write and likely faster to execute.
  8. Replies
    3
    Views
    2,567

    A few questions to point you in the right...

    A few questions to point you in the right direction:
    How will the constructor know how many characters that n points to?
    What sort of functions work according to the answer you just gave?
    How many...
  9. Here is a little tip to point you in the right...

    Here is a little tip to point you in the right direction.
    First consider:
    How would you represent an empty list? And how would you insert an item into an empty list?

    The answer to that should...
  10. You don't seem to have any idea how bad the...

    You don't seem to have any idea how bad the exponential time taken by the naive recursive approach is.
    Doubly-recursively calculating the Fib of N+1 takes more than twice the effort of calculating...
  11. Replies
    25
    Views
    2,593

    In other words - Selection Sort. Which of course...

    In other words - Selection Sort.
    Which of course you could also easily do without making an array first, and it's still easier than Bubble Sorting a linked-list.

    OP:
    You are not actually Bubble...
  12. Replies
    6
    Views
    5,356

    You have the original indexes, because you are in...

    You have the original indexes, because you are in fact sorting those.
    So your next step is to rewrite this such that the two comparisons against pivot both call a function called compare.
    ...
  13. Replies
    6
    Views
    1,081

    Trying to see what's going on with 10 items can...

    Trying to see what's going on with 10 items can be a little hard. It's a lot easier to debug the problem if you find the smallest possible case where it doesn't work. I.e.
    Does it work with 0...
  14. Replies
    24
    Views
    6,868

    Perhaps you're after the Levenshtein Distance...

    Perhaps you're after the Levenshtein Distance algorithm.
    That's the algorithm used to determine suggestions for misspelled words. It gives you a score on how different two strings are.

    Perhaps...
  15. Replies
    5
    Views
    2,356

    Easy way: Learn about push and pop operations....

    Easy way: Learn about push and pop operations. Then it's just a matter of:

    While the list is not empty, pop an item, and push it onto a new list.
    Then point the old list back at the new reversed...
  16. Replies
    9
    Views
    1,770

    From your description, the way to do it is not to...

    From your description, the way to do it is not to have three threads touch the same variable.
    Instead each thread should find its own "best" value, then once all threads have completed examine all...
  17. I'd go so far as to call it a mistake to provide...

    I'd go so far as to call it a mistake to provide a constructor when it would be generated for you, and has no work to do besides what it does when you let it generate this on its own.

    I.e. More...
  18. Replies
    9
    Views
    1,567

    The ideal for a text editor is the rope data...

    The ideal for a text editor is the rope data structure.
  19. Replies
    10
    Views
    9,920

    That's just it though, it doesn't because int's...

    That's just it though, it doesn't because int's are signed.
    0xffffffffU does though.
  20. Replies
    5
    Views
    3,460

    I think some images of the original 2D output and...

    I think some images of the original 2D output and your 3D output would help a lot in understanding the problem.
  21. Replies
    3
    Views
    794

    Lines 20 to 24 are unreachable here. There are no...

    Lines 20 to 24 are unreachable here. There are no options remaining besides key being either equal to, less than, or greater than leaf->num.
    The solution is to realise that the case actually belongs...
  22. This is like asking: "I flipped a coin and got...

    This is like asking: "I flipped a coin and got heads, why is that?"
  23. Well actually nowdays we've almost come full...

    Well actually nowdays we've almost come full circle it seems. Think ClickOnce etc.
  24. Replies
    6
    Views
    1,069

    So, in other words you want to draw a color...

    So, in other words you want to draw a color wheel?

    Use the scanline method, and calculate the angle and distance from the centre for each pixel, then color it according to those values. You'll...
  25. Replies
    8
    Views
    1,305

    There is virtually nothing more to the algorithms...

    There is virtually nothing more to the algorithms for stack operations than their description.
    Simply read what the stack operations do and implement that.
    Do not expect anyone here to write code...
Results 1 to 25 of 500
Page 1 of 20 1 2 3 4