<< October 9, 2003 | Home | October 11, 2003 >>

Sums Of Odd Integers

Here's a hint for a question I posted eight days ago:

"Can you write a function that calculates the sum of all odd integers from 1 to 2n+1?"

The answer is n2. If you don't know this, your function will be O(n) instead of O(1).