function todGreeting() {
   var now = new Date();
   var hour = now.getHours();
   var msg = "Hello, world!";
   if (hour <= 5)
      msg = "Early bird gets the worm.";
   else if (hour > 5 && hour < 12) {
      msg = "Good Morning!";
      if (hour == 10 && now.getMinutes() <= 30)
         msg += " Coffee time.";
   } else if (hour == 11)
      msg = "Anyone for an early lunch?";
   else if (hour >= 12 && hour <= 13)
      msg = "Lunch time -- enjoy.";
   else if (hour > 13 && hour <= 16)
      msg = "Good Afternoon.  A nap would be nice.";
   else if (hour == 17)
      msg = "It's the five o'clock hour.";
   else if (hour > 17 && hour <= 20)
      msg = "Good Evening!";
   else if (hour > 20 && hour <= 23) {
      if (hour == 22 && now.getMinutes() < 30)
         msg = "Is the 10:00 news on?";
      else
         msg = "It's past my bed time.";
   }
   return msg;
}
