import java.util.Arrays;
public class Caesar {
public static void main (String[] args) {
//user input
String [] input= {"bbcc"};
// turn user input from string to char, creates array.
char [] charinput = input.toCharArray();
// Arrays decleration
char [] abc={'a','b','c','d'};
char [] ABC={'A','B','C','D'};
/*
for (int i = 0; i <abc.length; i++){
// code to check if a char in string is in array abc
}
*/
}
}
why do I still get the error "Cannot resolve method 'toCharArray' in 'String'"? I looked for solution on line but all I found was to add "import java.util.Arrays;" and then it should work but it still doesn't.