The following configuration of gate is equivalent to
NAND gate
XOR gate
OR gate
NOR gate
from the circuit output of gate G1 is A+B and output of gate G2 is AB and final output Y is A+BAB
Y=A+BA+B=AA+AB+AB+BB=AB+AB which is exclusive OR