I have an array of strings
String[] jt = { "João Mendonça", "Mário Andrade", "João Mendonça"});
What you are supposed to do is verify if the array contains at least one character and has no repeated name , or in this specific case it contains a letter in min and has a repeated name. the expected output will be:
java.lang.IllegalArgumentException: nome repetido
My problem is how to check if you have at least one letter character and how to check if it has a repeated name.
Explaining better:
I have String Array of JT to which I want to do 2 checks:
1- Check if there is at least 1 character that is letter.
2 - Check if there are equal names: jt= {"nome","nome","nome")
, if there is a return
java.lang.IllegalArgumentException: nome repetido