Using Window.Alert()
With window.alert(), you can use an alert box to display data:
HTML file:
Displayed by browser:
<!DOCTYPE html>
<html>
<body>
<h1>My First Web Page</h1>
<p>My first paragraph.</p>
<script>
window.alert(5 + 6);
</script>
</body>
</html>
My First Web Page
My first paragraph.