What will be the output of the following Java code snippet that calculates the…
PYQ IBPS SO CRP SPL-XIII (2023)
What will be the output of the following Java code snippet that calculates the length of a string without using the built-in length() method?

- A.
The length of the string "Hello, World!" is: 13
- B.
The length of the string "Hello, World!" is: 12
- C.
Compilation Error
- D.
Runtime Error: String cannot be null
- E.
The length of the string "Hello, World!" is: 14
Attempted by 80 students.
Sign up free to check your answer
Sign up freeLoading lesson…

