import java.math.BigDecimal;
import java.math.RoundingMode;
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		double a = sc.nextDouble();
		double b = sc.nextDouble();
		String s = "-1";
		for(double i = 0D ; i < 10050D ; i += 1D) {
			if(Math.floor(i * 0.08D) == Math.floor(a) && Math.floor(i * 0.10D) == Math.floor(b)){
				BigDecimal bd = new BigDecimal(String.valueOf(i));
				BigDecimal bd1 = bd.setScale(0, RoundingMode.DOWN);
				s = bd1.toPlainString();
				break;
			}
		}
		sc.close();
			System.out.println(s);
	}
}
 import java.math.BigDecimal; BigDecimal java.math import java.math.RoundingMode; RoundingMode java.math import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		double a = sc.nextDouble();
		double b = sc.nextDouble();
		String s = "-1";
		for(double i = 0D ; i < 10050D ; i += 1D) {
			if(Math.floor(i * 0.08D) == Math.floor(a) && Math.floor(i * 0.10D) == Math.floor(b)){
				BigDecimal bd = new BigDecimal(String.valueOf(i));
				BigDecimal bd1 = bd.setScale(0, RoundingMode.DOWN);
				s = bd1.toPlainString();
				break;
			}
		}
		sc.close();
			System.out.println(s);
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		double a = sc.nextDouble();
		double b = sc.nextDouble();
		String s = "-1";
		for(double i = 0D ; i < 10050D ; i += 1D) {
			if(Math.floor(i * 0.08D) == Math.floor(a) && Math.floor(i * 0.10D) == Math.floor(b)){
				BigDecimal bd = new BigDecimal(String.valueOf(i));
				BigDecimal bd1 = bd.setScale(0, RoundingMode.DOWN);
				s = bd1.toPlainString();
				break;
			}
		}
		sc.close();
			System.out.println(s);
	} main {
		Scanner sc = new Scanner(System.in);
		double a = sc.nextDouble();
		double b = sc.nextDouble();
		String s = "-1";
		for(double i = 0D ; i < 10050D ; i += 1D) {
			if(Math.floor(i * 0.08D) == Math.floor(a) && Math.floor(i * 0.10D) == Math.floor(b)){
				BigDecimal bd = new BigDecimal(String.valueOf(i));
				BigDecimal bd1 = bd.setScale(0, RoundingMode.DOWN);
				s = bd1.toPlainString();
				break;
			}
		}
		sc.close();
			System.out.println(s);
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) double a = sc.nextDouble(); a sc.nextDouble() sc.nextDouble sc double b = sc.nextDouble(); b sc.nextDouble() sc.nextDouble sc String s = "-1"; s "-1" for(double i = 0D ; i < 10050D ; i += 1D) {
			if(Math.floor(i * 0.08D) == Math.floor(a) && Math.floor(i * 0.10D) == Math.floor(b)){
				BigDecimal bd = new BigDecimal(String.valueOf(i));
				BigDecimal bd1 = bd.setScale(0, RoundingMode.DOWN);
				s = bd1.toPlainString();
				break;
			}
		} double i = 0D ; double i = 0D ; i 0D i < 10050D i 10050D i += 1D i += 1D i 1D {
			if(Math.floor(i * 0.08D) == Math.floor(a) && Math.floor(i * 0.10D) == Math.floor(b)){
				BigDecimal bd = new BigDecimal(String.valueOf(i));
				BigDecimal bd1 = bd.setScale(0, RoundingMode.DOWN);
				s = bd1.toPlainString();
				break;
			}
		} {
			if(Math.floor(i * 0.08D) == Math.floor(a) && Math.floor(i * 0.10D) == Math.floor(b)){
				BigDecimal bd = new BigDecimal(String.valueOf(i));
				BigDecimal bd1 = bd.setScale(0, RoundingMode.DOWN);
				s = bd1.toPlainString();
				break;
			}
		} if(Math.floor(i * 0.08D) == Math.floor(a) && Math.floor(i * 0.10D) == Math.floor(b)){
				BigDecimal bd = new BigDecimal(String.valueOf(i));
				BigDecimal bd1 = bd.setScale(0, RoundingMode.DOWN);
				s = bd1.toPlainString();
				break;
			} Math.floor(i * 0.08D) == Math.floor(a) && Math.floor(i * 0.10D) == Math.floor(b) Math.floor(i * 0.08D) == Math.floor(a) Math.floor(i * 0.08D) Math.floor Math i * 0.08D i 0.08D Math.floor(a) Math.floor Math a Math.floor(i * 0.10D) == Math.floor(b) Math.floor(i * 0.10D) Math.floor Math i * 0.10D i 0.10D Math.floor(b) Math.floor Math b {
				BigDecimal bd = new BigDecimal(String.valueOf(i));
				BigDecimal bd1 = bd.setScale(0, RoundingMode.DOWN);
				s = bd1.toPlainString();
				break;
			} BigDecimal bd = new BigDecimal(String.valueOf(i)); bd new BigDecimal(String.valueOf(i)) BigDecimal bd1 = bd.setScale(0, RoundingMode.DOWN); bd1 bd.setScale(0, RoundingMode.DOWN) bd.setScale bd 0 RoundingMode.DOWN RoundingMode RoundingMode.DOWN s = bd1.toPlainString() s bd1.toPlainString() bd1.toPlainString bd1 break; sc.close() sc.close sc System.out.println(s) System.out.println System.out System System.out s String[] args args public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		double a = sc.nextDouble();
		double b = sc.nextDouble();
		String s = "-1";
		for(double i = 0D ; i < 10050D ; i += 1D) {
			if(Math.floor(i * 0.08D) == Math.floor(a) && Math.floor(i * 0.10D) == Math.floor(b)){
				BigDecimal bd = new BigDecimal(String.valueOf(i));
				BigDecimal bd1 = bd.setScale(0, RoundingMode.DOWN);
				s = bd1.toPlainString();
				break;
			}
		}
		sc.close();
			System.out.println(s);
	}
} public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		double a = sc.nextDouble();
		double b = sc.nextDouble();
		String s = "-1";
		for(double i = 0D ; i < 10050D ; i += 1D) {
			if(Math.floor(i * 0.08D) == Math.floor(a) && Math.floor(i * 0.10D) == Math.floor(b)){
				BigDecimal bd = new BigDecimal(String.valueOf(i));
				BigDecimal bd1 = bd.setScale(0, RoundingMode.DOWN);
				s = bd1.toPlainString();
				break;
			}
		}
		sc.close();
			System.out.println(s);
	}
} Main
import java.math.BigDecimal;
import java.math.RoundingMode;
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		double a = sc.nextDouble();
		double b = sc.nextDouble();
		String s = "-1";
		for(double i = 0D ; i < 10050D ; i += 1D) {
			if(Math.floor(i * 0.08D) == Math.floor(a) && Math.floor(i * 0.10D) == Math.floor(b)){
				BigDecimal bd = new BigDecimal(String.valueOf(i));
				BigDecimal bd1 = bd.setScale(0, RoundingMode.DOWN);
				s = bd1.toPlainString();
				break;
			}
		}
		sc.close();
			System.out.println(s);
	}
}

