Pergunta de entrevista da empresa Alida

Javascript code to Select every Other <tr> from table and change its background to grey and at the end print in console how many rows were color changed