#apc001a. [apc001_a]Two Integers

[apc001_a]Two Integers

Problem Statement

You are given positive integers XX and YY. If there exists a positive integer not greater than 101810^{18} that is a multiple of XX but not a multiple of YY, choose one such integer and print it. If it does not exist, print \-1\-1.

Constraints

  • 1X,Y1091 ≤ X,Y ≤ 10^9
  • XX and YY are integers.

Input

Input is given from Standard Input in the following format:

XX YY

Output

Print a positive integer not greater than 101810^{18} that is a multiple of XX but not a multiple of YY, or print \-1\-1 if it does not exist.


Sample Input 1

8 6

Sample Output 1

16

For example, 1616 is a multiple of 88 but not a multiple of 66.


Sample Input 2

3 3

Sample Output 2

-1

A multiple of 33 is a multiple of 33.