1. Using the String method charAt, write a loop that computes the number of words in the sentence given as the string sentence.
2. Write a loop that repeatedly asks for user input until a negative number is entered. Display each value entered and a farewell message when the loop ends.
3. What does the following loop display?
int n = 10;
while (n > 0)
{
System.out.println(n);
n = n - 3;
}
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here