Live data from Hacker News

A Gentle Introduction to Algorithm Complexity Analysis

discrete.gr

11–14 of 14 posts

Re: A Gentle Introduction to Algorithm Complexity Analysis

#11

The explanation of Big O in Grokking Algorithms was clearest for me. It doesn't assume any knowledge and even re-introduces logarithms and binary search before using them in examples: - Logarithms and binary search: https://livebook.manning.com/#!/book/grokking-algorithms/cha... - Big O: https://livebook.manning.com/#!/book/grokking-algorithms/cha...

THIS book was my first serious introduction to anything BigOh. Playful yet dead nuts on the mission to introduce self taught programmers like me the fundamentals the right way.

Re: A Gentle Introduction to Algorithm Complexity Analysis

#12

The explanation of Big O in Grokking Algorithms was clearest for me. It doesn't assume any knowledge and even re-introduces logarithms and binary search before using them in examples: - Logarithms and binary search: https://livebook.manning.com/#!/book/grokking-algorithms/cha... - Big O: https://livebook.manning.com/#!/book/grokking-algorithms/cha...

>It doesn't assume any knowledge and even re-introduces logarithms and binary search before using them in examples

So does the OP.

Re: A Gentle Introduction to Algorithm Complexity Analysis

#13

    for ( var i=0; i
In Javascript this will loop from 0 to n-1 inclusive regardless of using ++i or i++, because that loop 'stepping statement' happens after the loop body.

Its possible to combine the step in the test to go from 1 to n-1

    for ( var i=0; ++i
best to be aware of the quirk and just do

    for ( var i=1; i
Post reply on HN