import java.util.Scanner;

public class Main {

	public static void main(String[] args) {

		Scanner scan = new Scanner(System.in);

		int A = scan.nextInt();
		int B = scan.nextInt();
		int f = 0;

		for (int price = B*10; price < (B+1)*10; price++) {
			if ((int)((double)price*0.08 + 0.01) == A) {
				System.out.println(price);
				f++;
				break;
			}
		}

		if (f == 0) {
			System.out.println(-1);
		}

	}

} import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {

		Scanner scan = new Scanner(System.in);

		int A = scan.nextInt();
		int B = scan.nextInt();
		int f = 0;

		for (int price = B*10; price < (B+1)*10; price++) {
			if ((int)((double)price*0.08 + 0.01) == A) {
				System.out.println(price);
				f++;
				break;
			}
		}

		if (f == 0) {
			System.out.println(-1);
		}

	}

} Main public static void main(String[] args) {

		Scanner scan = new Scanner(System.in);

		int A = scan.nextInt();
		int B = scan.nextInt();
		int f = 0;

		for (int price = B*10; price < (B+1)*10; price++) {
			if ((int)((double)price*0.08 + 0.01) == A) {
				System.out.println(price);
				f++;
				break;
			}
		}

		if (f == 0) {
			System.out.println(-1);
		}

	} main {

		Scanner scan = new Scanner(System.in);

		int A = scan.nextInt();
		int B = scan.nextInt();
		int f = 0;

		for (int price = B*10; price < (B+1)*10; price++) {
			if ((int)((double)price*0.08 + 0.01) == A) {
				System.out.println(price);
				f++;
				break;
			}
		}

		if (f == 0) {
			System.out.println(-1);
		}

	} Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int A = scan.nextInt(); A scan.nextInt() scan.nextInt scan int B = scan.nextInt(); B scan.nextInt() scan.nextInt scan int f = 0; f 0 for (int price = B*10; price < (B+1)*10; price++) {
			if ((int)((double)price*0.08 + 0.01) == A) {
				System.out.println(price);
				f++;
				break;
			}
		} int price = B*10; int price = B*10; price B*10 B 10 price < (B+1)*10 price (B+1)*10 (B+1) B 1 10 price++ price++ price {
			if ((int)((double)price*0.08 + 0.01) == A) {
				System.out.println(price);
				f++;
				break;
			}
		} {
			if ((int)((double)price*0.08 + 0.01) == A) {
				System.out.println(price);
				f++;
				break;
			}
		} if ((int)((double)price*0.08 + 0.01) == A) {
				System.out.println(price);
				f++;
				break;
			} (int)((double)price*0.08 + 0.01) == A (int)((double)price*0.08 + 0.01) (double)price*0.08 (double)price 0.08 0.01 A {
				System.out.println(price);
				f++;
				break;
			} System.out.println(price) System.out.println System.out System System.out price f++ f break; if (f == 0) {
			System.out.println(-1);
		} f == 0 f 0 {
			System.out.println(-1);
		} System.out.println(-1) System.out.println System.out System System.out -1 1 String[] args args public class Main {

	public static void main(String[] args) {

		Scanner scan = new Scanner(System.in);

		int A = scan.nextInt();
		int B = scan.nextInt();
		int f = 0;

		for (int price = B*10; price < (B+1)*10; price++) {
			if ((int)((double)price*0.08 + 0.01) == A) {
				System.out.println(price);
				f++;
				break;
			}
		}

		if (f == 0) {
			System.out.println(-1);
		}

	}

} public class Main {

	public static void main(String[] args) {

		Scanner scan = new Scanner(System.in);

		int A = scan.nextInt();
		int B = scan.nextInt();
		int f = 0;

		for (int price = B*10; price < (B+1)*10; price++) {
			if ((int)((double)price*0.08 + 0.01) == A) {
				System.out.println(price);
				f++;
				break;
			}
		}

		if (f == 0) {
			System.out.println(-1);
		}

	}

} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {

		Scanner scan = new Scanner(System.in);

		int A = scan.nextInt();
		int B = scan.nextInt();
		int f = 0;

		for (int price = B*10; price < (B+1)*10; price++) {
			if ((int)((double)price*0.08 + 0.01) == A) {
				System.out.println(price);
				f++;
				break;
			}
		}

		if (f == 0) {
			System.out.println(-1);
		}

	}

}