{"raw_statement":[{"iden":"statement","content":"Bitwise exclusive OR (or bitwise addition modulo two) is a binary operation which is equivalent to applying logical exclusive OR to every pair of bits located on the same positions in binary notation of operands. In other words, a binary digit of the result is equal to 1 if and only if bits on the respective positions in the operands are different.\n\nFor example, if _X_ = 10910 = 11011012, _Y_ = 4110 = 1010012, then:\n\n<center>_X_ _xor_ _Y_  =  6810  =  10001002.</center>Write a program, which takes two non-negative integers _A_ and _B_ as an input and finds two non-negative integers _X_ and _Y_, which satisfy the following conditions:\n\n*   _A_ = _X_ + _Y_\n*   _B_  =  _X_ _xor_ _Y_, where _xor_ is bitwise exclusive or.\n*   _X_ is the smallest number among all numbers for which the first two conditions are true."},{"iden":"input","content":"The first line contains integer number _A_ and the second line contains integer number _B_ (0 ≤ _A_, _B_ ≤ 264 - 1)."},{"iden":"output","content":"The only output line should contain two integer non-negative numbers _X_ and _Y_. Print the only number _\\-1_ if there is no answer."},{"iden":"examples","content":"Input\n\n142\n76\n\nOutput\n\n33 109"}],"translated_statement":[{"iden":"statement","content":"按位异或（或按位模二加法）是一种二元运算，它等价于对操作数二进制表示中相同位置的每一位应用逻辑异或。换句话说，结果的二进制位等于 1，当且仅当操作数中对应位置的位不同。\n\n例如，若 #cf_span[X = 10910 = 11011012], #cf_span[Y = 4110 = 1010012]，则：\n\n编写一个程序，输入两个非负整数 #cf_span[A] 和 #cf_span[B]，找出两个非负整数 #cf_span[X] 和 #cf_span[Y]，满足以下条件：\n\n第一行包含整数 #cf_span[A]，第二行包含整数 #cf_span[B]（#cf_span[0 ≤ A, B ≤ 264 - 1]）。\n\n输出仅一行，包含两个非负整数 #cf_span[X] 和 #cf_span[Y]。若无解，请仅输出 _-1_。"},{"iden":"input","content":"第一行包含整数 #cf_span[A]，第二行包含整数 #cf_span[B]（#cf_span[0 ≤ A, B ≤ 264 - 1]）。"},{"iden":"output","content":"输出仅一行，包含两个非负整数 #cf_span[X] 和 #cf_span[Y]。若无解，请仅输出 _-1_。"},{"iden":"examples","content":"输入\n14\n276\n输出\n33 109"}],"sample_group":[],"show_order":[],"formal_statement":"**Definitions**  \nLet $ A, B \\in \\mathbb{Z}_{\\geq 0} $ with $ 0 \\leq A, B \\leq 2^{64} - 1 $.  \nWe seek $ X, Y \\in \\mathbb{Z}_{\\geq 0} $ such that:  \n$$\nX + Y = A \\quad \\text{and} \\quad X \\oplus Y = B\n$$\nwhere $ \\oplus $ denotes bitwise XOR.\n\n**Constraints**  \n1. $ 0 \\leq A, B \\leq 2^{64} - 1 $  \n2. $ X, Y \\geq 0 $\n\n**Objective**  \nFind $ X, Y \\in \\mathbb{Z}_{\\geq 0} $ satisfying:  \n$$\nX + Y = A \\quad \\text{and} \\quad X \\oplus Y = B\n$$  \nIf no such pair exists, output $-1$.","simple_statement":null,"has_page_source":false}