String s = "Hello";
System.out.println(s.length());What is printed?
- Acheck_circle
5
- B
Hello
- C
6
- D
4
Explanation
The string "Hello" contains 5 characters, so length() returns 5.
AP Computer Science A· difficulty 2/5
String s = "Hello";
System.out.println(s.length());What is printed?
5
Hello
6
4
Explanation
The string "Hello" contains 5 characters, so length() returns 5.
Want 10 more like this — adaptive to your weak spots?