The key element here is to try to implement the program without using an if statement. 

Here's how my program works. 

I compile my code: 

-bash-4.1$ javac Sixteen.java

I run it with the first time being later in the day than the second one: 

-bash-4.1$ java Sixteen
Enter the first time: 1006
Enter the second time: 0941
23 hours 35 minutes

I run it again with the second time being later in the day: 

-bash-4.1$ java Sixteen
Enter the first time: 0941
Enter the second time: 1006
0 hours 25 minutes
-bash-4.1$

Both differences are calculated correctly. 

The program does not use the boolean type (if/while/etc.) at all.