That's a big problem. That assignment is simply copying the pointer to the string, which, as we can find by travelling up the stack, is just data's value. That array is getting overwritten every...
What you're looking for is a dictionary-based encoding scheme. The word "dictionary" alone should provide you ample avenues if you search, but "LZW" might be a good starting place.
Well, if you have an algorithm to find the longest increasing subsequence (which is already O(n*lg(n))), and it turns out that the size of the subsequence returned is >= L, then any possible...
We need more information than that. What do you mean, "in linked lists"? Does each node contain information about a different degree in the polynomial? Are you guaranteed the variable is always...
Ah, you're right. So, to rectify, any time C is a destination, that may also fill one of the required "source" C's, meaning that a node X should appear in the list max(source X's, dest X's) times. ...
I'm having trouble understanding exactly what you want to achieve here. Do you think you could list the logical sequence of events you're aiming for? Then I might be able to help you.
That's the Travelling Salesman problem, which is NP-Complete. You won't find a non-probabilistic algorithm that's better than O(k^N) because none has been found.