import java.util.Arrays; import java.util.HashSet; import java.util.LinkedList; import java.util.OptionalInt; import java.util.Scanner; import java.util.Set; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); final int A = sc.nextInt(); final int B = sc.nextInt(); int min = Integer.MAX_VALUE; int min_A = -1; int min_B = -1; for(int a = 0; a <= 1000; a++){ for(int b = 0; b <= 1000; b++){ final int sum = a + b; if(sum == 0){ continue; } final int A_val = (100 * a) / (sum) + (((100 * a) % sum) * 2 >= sum ? 1 : 0); final int B_val = (100 * b) / (sum) + (((100 * b) % sum) * 2 >= sum ? 1 : 0); //System.out.println(A_val + " " + B_val); if(A_val == A && B_val == B && sum < min){ min = sum; min_A = a; min_B = b; } } } System.out.println(min); } }