Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

it's the summation of numbers from 1 to n which is n(n+1)/2. This reduces to quadratic complexity because big O notation ignores all coefficients and terms that scale slower


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: