I need to make methods that check errors in input. I want them to return 2 things : boolean for if the check passed. and string for telling what the error is .
How to do it ?
//what I want
System.out.println("this is the error :"+str);