title: How to count uppercase and lowercase letters in a string?
body: <p>yo, so im trying to make a program that can take string input from the user for instance: "ONCE UPON a time" and then report back how many upper and lowercase letters the string contains: </p>
  
  <p>output example:  the string has 8 uppercase letters
  the string has 5 lowercase letters, and im supposed to use string class not arrays, any tips on how to get started on this one? thanks in advance, here is what I have done so far :D! </p>
  
  <pre><code>import java.util.Scanner;
  public class q36{
      public static void main(String args[]){
  
          Scanner keyboard = new Scanner(System.in);
          System.out.println("Give a string ");
          String input=keyboard.nextLine();
  
          int lengde = input.length();
          System.out.println("String: " + input + "\t " + "lengde:"+ lengde);
  
          for(int i=0; i&lt;lengde;i++) {
              if(Character.isUpperCase(CharAt(i))){
  
              }
          }
      }
  }
  </code></pre>