/** * Counts the number of 'a's in text entered by the user. */ import java.util.Scanner; public class CountLetters { public static void main(String[] args) { Scanner in = new Scanner(System.in); System.out.println("Enter some text."); String input = in.nextLine(); if (count == 1) System.out.println("There is 1 'a' in your input."); else System.out.println("There are " + count + " 'a's in your input."); } }