why is 24 * 60 * 60 * 1000 * 1000 divided by 24 * 60 * 60 * 1000 not equal to 1000 in Java?
You need to start with 24L * 60 * ... because the int overflows.
Your question BTW is a copy/paste of Puzzle 3: Long Division from Java Puzzlers ;)