Write a JavaScript program to change style of a text at runtime.
<html>
<head>
<title>Change Style of a Text at Runtime</title>
<script>
function changeStyle()
{
document.getElementById('mydiv').style.color = "Red"
document.getElementById('mydiv').style.backgroundColor = "cyan"
document.getElementById('mydiv').style.width = "70"
document.getElementById('mydiv').style.height = "70"
}
</script>
</head>
<body>
<div id="mydiv">
Welcome to JavaScript
</div>
<input type="button" value="Click" onclick="changeStyle()">
</body>
</html>
