I have a Javascript in which I need to paste the current time in a format HH:MM AM/PM. There\'s one catch - I need to put the time that starts in two hours from now, so for
Note that the accepted answer, while good, does not appear to meet the format requirement of: HH:MM AM/PM. It returns midnight as "0:0:38am" and so forth.
There are many ways one could do this and one alternative is shown below. Click the "Run Code Snippet" to test.