Microsoft interview question

Find number of HTML table rows optimally