import java.util.HashMap; import java.util.Map; import java.util.Scanner; public class Main { public static void main(String[] args) throws Exception { Scanner sc = new Scanner(System.in); int m = 100; int m2 = 1000; int max = 0; for (int x = 1; x < m; x++) { for (int y = x + 1; y <= m; y++) { Map map = new HashMap<>(); int cnt = 0; for (int a = 0; a < m; a++) { for (int b = a + 1; b <= m; b++) { int v1 = (x + a) % b; int v2 = (y + a) % b; map.put(v1 * m2 + v2, a * m2 + b); cnt++; } } max = Math.max(max, map.size()); if (map.size() == 3903) { System.out.println("? " + x); int v1 = sc.nextInt(); System.out.println("? " + y); int v2 = sc.nextInt(); int v = v1 * m2 + v2; int ab = map.get(v); int a = ab / m2; int b = ab % m2; System.out.println("! " + a + " " + b); sc.close(); return; } } } sc.close(); System.out.println(max); } }