Write a JavaScript program to display the greetings?
Program: <html> <body> <script type="text/javascript"> var d=new Date(); alert(d); document.write...

https://www.computersprofessor.com/2016/06/write-javascript-program-to-display_11.html
Program:
<html>
<body>
<script type="text/javascript">
var d=new Date();
alert(d);
document.write(d);
var time=d.getHours();
document.writeln("< br >");
document.writeln(time);
if(time < 10)
{
document.write(" < b > Good morning< /b > ");
}
else
{
document.write("< b > Good day< /b > ");
}
</script>
<p>this example demonstrates the If statement</p>
<p>if the time on your browser is less than 10, you will get a good morning</p>
</body>
</html>
Out Put: