console.log("Hello, World!");
console.error("Error, World!"); // For errors
console.warn("Warning, World!"); // For warnings
console.clear(); // To clear the console
//give output on the console
console.log("Hello World!");
//also u can use alert to create a pop up
alert("Hello World!");
//how to print hello world in html using javascript
document.write("Hello World");
window.alert("hello world");
console.log("Hello World);
// 1. Using console.log()
console.log("Hello World");
// console.log() is used in debugging the code.
// 2. Using alert()
alert("Hello, World!");
// // The alert() method displays an alert box over the current window with the specified message.
// 3. Using document.write()
document.write("Hello, World!");
// // document.write() is used when you want to print the content to the HTML document.
//Answer by Anshul Soni
//Visit my my website - https://anshulsoni.netlify.app/