package Lect25Callstack;

public class CallStack { 
	public int numberLowerCase(String theStr) {
		int count = 0;
		
		for (int i=0; i<theStr.length(); i++) {
			if (Character.isLowerCase(theStr.charAt(i))) {
				count++;
			}
		}
		
		return count;
	}
	
	public void stats(String str) {
		int lower = numberLowerCase(str);
		int upper = str.length() - lower;
		System.out.println("[String: " + str + "]");
		System.out.println("[Lower case count: " + lower + "]");
		System.out.println("[Upper case count: " + upper + "]");
		
	}
	
	public static void main(String[] args) {
		new CallStack().stats("HellO");
	}
}
