<!DOCTYPE HTML>
<html>
<head>
<meta charset="utf-8">
</head>
<body>
<input id="recalcInput" type="text" value="100">
<span id="recalcedSum"></span>
<script>
document.getElementById('recalcInput').addEventListener('input', function() {
var output = document.getElementById('recalcedSum');
output.innerHTML = this.value - 50;
});
</script>
</body>
</html>