# XOR: Is it possible to get $a$ and $b$ if I have $a \oplus b$ and $a \times b$?

Intuitively I would say yes but I can't find a way to prove it. I tried with small values and bruteforcing shows that there seems to only be one solution given a distinct tuplet.

For example $$(1,72)$$ has only $$(8,9)$$ as valid $$a$$ and $$b$$ values. Is there a way to do this mathematically?

• Welcome to Puzzling.SE! For the uninitiated in the room (such as me), would you mind explaining what precisely is meant by the little symbol that looks like a Phillips head screw? Thanks, and have a great day! – Brandon_J May 4 at 17:28
• It’s bitwise addition modulo 2, @Brandon_J – El-Guest May 4 at 17:30
• Thanks for letting me know, @El-Guest . – Brandon_J May 4 at 17:30
• So essentially, I convert the number to binary (for exapmle, 3-->00011, 24-->11000), then perform theXOR operation on each pair of bits, and then convert back to a normal number (27)? – Brandon_J May 4 at 17:54
• Not sure this is a puzzle, but I'm glad you got your answer. (Please don't forget to $\color{green}{\checkmark \small\text{Accept}}$ it!) – Rubio May 5 at 4:34

By counterexample, $$a,b$$ pair is clearly not unique.
The pairs $$(5,9)$$ and $$(3,15)$$ both multiply to $$45$$, and add bitwise to $$12$$.
$$5 \oplus 9 = 12$$, $$5 \times 9 = 45$$
$$3 \oplus 15 = 12$$, $$3 \times 15 = 45$$
{"found_math": true, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 1, "mathjax_display_tex": 0, "mathjax_asciimath": 0, "img_math": 0, "codecogs_latex": 0, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0, "katex": 0, "math-container": 13, "wp-katex-eq": 0, "align": 0, "equation": 0, "x-ck12": 0, "texerror": 0}