Why? Big O notation gives abstraction and the opportunity for generalizing. When? Whenever you want to measure one parameter from the changing volume of another. Where? It is best to look at fairly atomic sections of code that make one specific business logic.
Full article