lshevtsov
Joined 17 years ago
Joined 17 years ago
[1] https://mailtrap.io.
As for the first one - as i understand, this will spoil the original array, as it is assigned by reference; so by writing the string into `numbersOrStrings`, you also write it into `numbers`, thus violating the type.
here's a vanilla implementation of Quicksort https://github.com/leonid-shevtsov/uni-programming/blob/mast...
and here's the function to generate data that causes the custom implementation to go O(n^2) https://github.com/leonid-shevtsov/uni-programming/blob/mast...
It's not practical, but something uniquely valuable can be grown from the constraints.
I understand, though, that explaining each and every line of code was done for the sake of learning C.
EDIT: and the cost of programmer hours required to save a gig of RAM is orders of magnitude more.