Q:

On Keyup action for multiple tr's and td's

Problem: I need access using the on keyup Jquery function on every row of a table. 
I have multiple tables I need to do this for, but for now I'm starting with one. Driving by user selections info that drives that number of rows in the table. So it could 1 or could be up to 15. I need to multiply two inputs and output that to a td on the same row. The on keyup fires when the last td multiplied in the row is chosen. 
I've been able to get it working on the first row, but no rows after work. The two td's stay the same in all tables. I've tried a few different ways of isolating the tr's with no success. 
Here's the function I've been working with: 
//The td location I want to output to
<td>
  <span id="mcalPremium">$</span>
</td>

 $("#alSublineValSubmitTBL tbody tr td:nth-child(11) input").on('keyup', function (e) {
    var ex = $("#alSublineValSubmitTBL tbody tr td:nth-child(11) input").val();
    var r = $("#alSublineValSubmitTBL tbody tr td:nth-child(9) input").val();
    var exp = parseInt(ex);
    var rate = parseFloat(r);
    var premium = rate * exp;

    //display premium in premium field
    //#mcalPremium is a span within the table. It is the precise location I want to display the multiplied number.

    $('#mcalPremium').html('$' + premium).digits();

});

 //Insert comma every for premium
    $.fn.digits = function () {
        return this.each(function () {
            $(this).text($(this).text().replace(/(\d)(?=(\d\d\d)+(?!\d))/g, "$1,"));
        });
    };

As always your help is greatly appreciated. 

A:

So reference the element and use it to find the other input in the same row. It is weird you are only listening to the event on one of the two inputs, but I will follow your way.

$("table").on("input", "td:nth-child(3)", function () {
   var cell = $(this)
   var input1 = +cell.find("input").val() || 0
   var input2 = +cell.parent().find("td:nth-child(2) input").val() || 0
   cell.parent().find("span.result").text(input1+input2)
});
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<table>
  <tr>
    <td>One</td>
    <td><input type="number" value="1"/></td>
    <td><input type="number" value="1"/></td>
    <td><span class="result"></span></td>
  </tr>
  <tr>
    <td>TWO</td>
    <td><input type="number" value="2"/></td>
    <td><input type="number" value="2"/></td>
    <td><span class="result"></span></td>
  </tr>
  <tr>
    <td>THREE</td>
    <td><input type="number" value="3"/></td>
    <td><input type="number" value="3"/></td>
    <td><span class="result"></span></td>
  </tr>
</table>

