<!DOCTYPE html>
<html>
<head>
<style>
.mystyle {
    width: 300px;
    height: 50px;
    background-color: coral;
    color: white;
    margin-bottom: 10px;
}


.newClassName {
    width: 400px;
    height: 100px;
    background-color: lightblue;
    text-align: center;
    font-size: 25px;
    color: navy;
    margin-bottom: 10px;
}

</style>
</head>
<body>

<p>Click the button to change the value of the class attribute of DIV to "newClassName".</p>

<div id="myDIV" class="mystyle">
I am a DIV element
</div>

<button onclick="myFunction()">Try it</button>

<script>
function myFunction() {
    document.getElementById("myDIV").className = "newClassName";
}
</script>

</body>
</html>