Unterschied zwischen Java HH: mm und hh: mm bei SimpleDateFormat

Was ist der Unterschied zwischen den Formaten kk: mm, HH: mm und hh: mm?

    SimpleDateFormat broken = new SimpleDateFormat("kk:mm:ss");
    broken.setTimeZone(TimeZone.getTimeZone("Etc/UTC"));
    SimpleDateFormat working = new SimpleDateFormat("HH:mm:ss");
    working.setTimeZone(TimeZone.getTimeZone("Etc/UTC"));
    SimpleDateFormat working2 = new SimpleDateFormat("hh:mm:ss");
    working.setTimeZone(TimeZone.getTimeZone("Etc/UTC"));

    System.out.println(broken.format(epoch));
    System.out.println(working.format(epoch));
    System.out.println(working2.format(epoch));

druckt:

24:00:00
00:00:00
05:30:00

Antworten auf die Frage(5)

Ihre Antwort auf die Frage