Dapatkan jam sebagai angka (0-23) dari suatu Waktu
=HOUR(serial_number)
| Parameter | Deskripsi |
|---|---|
serial_number |
A valid Excel time. |
The HOUR function returns the hour from of a time or date as a number between 0-23. For example:
=HOUR("9:00 AM") // returns 9
=HOUR("9:00 PM") // returns 21
The HOUR function ignores minutes and seconds. For example, when given the time "6:30 PM", HOUR returns 18:
=HOUR("6:30 PM") // returns 18
Some Excel dates include time. When given a date that includes time, the HOUR function will extract the hour and ignore the date. For example, with 29
=HOUR(A1) // returns 6
You can use the HOUR function to extract the hour and feed the result into another formula, like the TIME function. For example, with the time "8:00 A
=TIME(HOUR(A1),30,0) // returns 8:30 AM