Q. What is the output of System.out.println(‘Z’ – ‘A’);?

A
25
B
26
C
1
D
Z-A
Solution:

‘Z’ (90) – ‘A’ (65) = 25, calculated as the difference in ASCII values.

Entri Contact Image

Get Expert Advice for Free: Register for Your Free Consultation Now!