I am working on a dynamic form, the rows are having parent dropdowns, and when we select a parent it adds new ROWs for number of childs, I have given classes to each child rows.
try
$('tr.partnumber_2_sub').last().remove()