<head>
<meta charset="utf-8">
<title></title>
<script type="text/javascript">
document.querySelector('table').onclick = function(e) {
let target = e.target;
if (target.tagName != 'BUTTON') return;
let cnt = target.closest('td').querySelector('.cnt');
cnt.innerText = parseInt(cnt.innerText, 10)+1;
};
</script>
</head>