programming * math = headache;
I am reading this nice little book called Accelerated c++, its a good book, but i have been out of school for some years, and have forgotten a lot of things, or maybe i should have payed more attention in school, yeah well hum.
I'm getting stuck at these exercises in this book, one right now mi to ..... to figure out,
" exercise 3-1
Suppose we wish to find the median of a collection of values. Assume that we have read some of the values so fare, and that we have no idea how many values remain to be read.
Prove that we cannot afford to discard any of the values that we have read. hint: One proof strategy is to assume that we can discard a value, and then find values for the unread--and therefore unknown--part of our collection that would cause the median to be the value that we discarded. "
Now i know what a median is (i think :D) , but i don't know what " Prove that we cannot afford to discard any of the values that we have read " means, I have no idea how to do that, I don't think its how to program it thats the problem, i don't even know how to do it in real life, and google keeps annoying me, wont give me the answer. :(
There you have it another few days in the life of a newbie c++ programmer, with an increasingly bad headache.
Ok, now who stole my aspirin.....