Algorithms

The conventional wisdom for when to use a linked list over contiguous storage hasn’t applied for years: you have to test. If everything is in a cache, a vector might outperform a linked list for insertion. Algorithm patterns Brute Force Divide and Conquer Karatsuba‚Äôs Integer Multiplication – it is possible to perform multiplication of large numbers in (many) fewer operations than the usual brute-force technique of “long multiplication.” As discovered by Karatsuba (Karatsuba and Ofman 1962). [Read More]