How to know which nth-child?

There is code:
<div class="tr"></div>
<div class="tr"></div>
<div class="tr"></div>
<div class="tr"></div>
<div class="tr"></div>

Respectively 5 lines. Like when you click on a certain - to know what she's nth-child , or just what's her serial number?
March 12th 20 at 07:59
1 answer
March 12th 20 at 08:01
Solution
Solved.
$('.tr').click(function(){
$(this).index();
})

Find more questions by tags jQuery