Finding the Median in Linear time
Here are three C++ programs to find the median of a set of numbers. The first is short and simple. The last is fiddly and fast. Simple but not linear (n*log n time): Sort using STL sort (presumably quicksort), then find the middle value: #include #include int main() { int A[7] = {23, 1, 33, […]
Programming interviews Exposed (Aug 2007)
Programming, 9/10 – Aug 2007 This book should really be kept a secret because if everyone read it before a programming interview, all the good jobs would be taken. It’s an excellent refresher to put you back to fresh-out-of-uni programming knowledge level. It covers Programming Problems, Logic Puzzles and Knowledge based problems with a very […]
Programming Pearls (Jon Bentley)
Programming, 8/10 – Aug 2007 The chapters on algorithms and efficiency (performance, code tuning and space tuning) make this book brilliant. The explanation and benchmarking of the different sorting and searching technique’s (especially quicksort) are almost fundamental reading for anyone that has a programming interview with a top company. Beware, in amongst the pearls there […]
Harry Potter and the Deathly Hallows (J. K. Rowling)
Fantasy, 8/10 – July 2007 I was dreading the possibility of a dark close to this series but I was delighted with the happy fairy tale ending (Harry Potter is a children’s book after all). I’m going to miss Harry, but I’ve decided if I ever have children, I’ll definitely read it to them. Harry […]