What is displayed on the console when running the following program? class Test { public static void main(String[] args) { try { System.out.println("Welcome to Java"); int i = 0; int y = 2/i; System.out.println("Welcome to Java"); } catch (RuntimeException ex) { System.out.println("Welcome to Java"); } finally { System.out.println("End of the block"); } } }
A.
The program displays Welcome to Java three times followed by End of the block.
B.
The program displays Welcome to Java two times followed by End of the block.
C.
The program displays Welcome to Java three times.
D.
The program displays Welcome to Java two times.