Answer:
public static boolean beginsWithZ(String word){
if(string == null || string.length() == 0)
return 0;
if(word.charAt(0) == 'Z' || word.charAt(0) == 'z')
return 1;
else
return 0;
}
Explanation:
This method is a boolean method, meaning it returns true if the string begins with Z or z and false otherwise. So:
The Java command charAt() let's you find the character at each position of the string, so i use it.
public static boolean beginsWithZ(String word){
if(string == null || string.length() == 0)
return 0;
if(word.charAt(0) == 'Z' || word.charAt(0) == 'z')
return 1;
else
return 0;
}
<span>1 X 25 + 1 X 24 + 1 X 23 + 0 X 22 + 1 X 21 + 1 X 20 thus your Answer is C</span>
The correct answer is D. All of the methods listed above are ways of inserting new sheets into a workbook.