JSFiddle - React, Tailwind, and code Playground
HTML
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
<html>
<span id="answer"></span>
</html>
JavaScript
$(document).ready(function() {
old_arr = [[1,1],[2,8],[3,12],[4,13],[5,23],[6,30],[7,41],[8,44],[9,50]];
new_arr = old_arr.reduce(function(a, b, c, d) { if (a.length) {a.push([d[c][0], d[c][1]-d[c-1][1]])} else {a = [b]} return a;}, []);
console.log(new_arr);
$("#answer").html(JSON.stringify(new_arr));
});