im creating a method that counts the occurances of random characters in another method but i cant seem to figure out how to bring in the random characters in from the other method the code is supposed to create an array of 26 integers then count and store the occurances of the random characters this is my code up until now:
public void add (char fromChar, char toChar){
int range = toChar - fromChar;
int seed = fromChar * toChar;
Random rr = new Random(seed);
for (int i = 0; i < charArray; ++i) {
char randomChar = (char)(fromChar + rr.nextInt(range));
System.out.println("Next character: " + randomChar);
}
public int[] countLetters(){
int [] countLetters =new int[26];
char current;
for(int i=0; i<countletters.length;> current=.charAt(i);
if (current >= 'a' && current <= 'z'){
countLetters[current-'a']++;
}
}
return null;
}