trying to create a matcher for finding if title is not correct i.e. has to be mr, mrs, miss etc..but this allows mrmrmr etc when it should not. tried different setups to keep failing i.e. [[]] or ().
public void valTitle(){
//validate title
while (this.title.matches("^[\\s]+$")
||this.title.matches("")
||this.title.matches("[^m]&&[^r]*")
){
System.out.println("Title can not"
+ " be empty or have spaces, must contain "
+ "a-z characters and has to be correct "
+ "length in size i.e. Mr or Miss");
System.out.println("Enter your title ?");
title = inputDetails.nextLine();
}
}