JavaScript

JavaScript – Write Program to Print Hello World!!!

JavaScript is scripting language which is similar to C. It is syntax and logic are similar to C, C++ and Java.

But Java is completely different then JavaScript Keep in mind. JavaScript has fewer features than the C, C++ like we don’t have a specialized pointer in JavaScript because it is a client-side scripting programming language.

We can use an array to make different kinds of objects and similar variables.

There are many ways to show output, such as you can directly make variable or object (DOM) or document and you can pass the result. But here we are using another method which is an alert dialog box.

HTML / JS Code

<html>
 <head><title>JavaScript</title></head>
 <body>
  <h1>Hello</h1>
   <script type='text/javascript'>
    alert('Hello World!');
   </script>
 </body>
</html>

Output

Alert Box on JavaScript

Next: Learn How to Write First Script

Back to top button

Adblock Detected

Please turn off your Adblocker to view your content.