level 1
1362433396
楼主
<script> $(function(){ var collection = $("tr"); console.log(collection[2]) $("<th>平均成绩</th>").appendTo(collection[0]) for(var x=1;x<collection.length;x++ ){ var number=((parseInt(collection[x].find("td:gt(4)").text())+parseInt(collection[x].find("td:gt(5)").text())+parseInt(collection[x].find("td:gt(5)").text()))/3).toFixed(1); var y = $("<td>"+number+"</td"); y.appendTo(collection[x]); } }); </script>
2020年12月30日 06点12分
1