The deeply nested links inside the div are our test subjects. The two functions, getPageOffsetLeft, and getPageOffsetLeft_Iterative calculate the distance of each header from the left side of the page.

getPageOffsetLeft calls itself recursively, passing the el param's offsetParent to itsself.

getPageOffsetLeft_Iterative achieves the same result in an empty for loop.

In the alert box, distance should be always the same. Look for a difference in the value for time in ms (lower number is faster).