how do i create a button that adds a value to another value, i tried like this but every time i run it it makes everything disappear and I only get the operation
<script>
var x= 40;
var y= 40;
document.write(x);
</script><br>
<button onclick="bottone1()" class="butto">+</button>
<script>
function bottone1(){
document.write(x+y)
}
</script>