Murex Interview Question

Hackerrank: 4 questions, you can choose between C++, Python and Java, but Java is preferred as the final interview would be in Java. The questions were not hard, and I feel like some of them were very language specific, like how to throw an error.