public class test { public static void main(String[] args) { char[] arr1 = {' ', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9'}; char[] arr2 = {' ', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9'}; char[] arr3 = {'0', '1', '2', '3', '4', '5', '6', '7', '8', '9'}; //last psw -> 900 char firstcurrent = '9'; char seccurrent = '0'; char thirdcurrent = '0'; int i=0, j=0, k=0; //continue from 900 up to 999 i = new String(arr1).indexOf(firstcurrent); j = new String(arr2).indexOf(seccurrent); k = new String(arr3).indexOf(thirdcurrent); for (;i