import java.util.Arrays; import java.util.HashSet; import java.util.LinkedList; import java.util.Scanner; import java.util.Set; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); for(int i = 0; i < 10; i++){ for(int j = 0; j < 10; j++){ for(int k = 0; k < 10; k++){ System.out.println(i + "" + j + "" + k); if(sc.next().equals("unlocked")){ return; } } } } } }