What is the result of casting a `double` to an `int` in Java?
Casting a `double` to an `int` causes the program to throw a runtime error.
Iâ€™m disappointed with this answer. Casting a `double` to an `int` is allowed in Java, but it truncates the decimal.
Can you explain the correct way to handle casting from `double` to `int`?