  For nonempty sets $A,B$ of nonnegative integers and an integer $n$, let
$r_{A,B}(n)$ be the number of representations of $n$ as $a+b$ and $d_{A,B}(n)$
be the number of representations of $n$ as $a-b$, where $a\in A, b\in B$. In
this paper, we determine the sets $A,B$ such that $r_{A,B}(n)=1$ for every
nonnegative integer $n$. We also consider the \emph{difference} structure and
prove that: there exist sets $A$ and $B$ of nonnegative integers such that
$r_{A,B}(n)\ge 1$ for all large $n$, $A(x)B(x)=(1+o(1))x$ and for any given
nonnegative integer $c$, we have $d_{A,B}(n)=c$ for infinitely many positive
integers $n$. Other related results are also contained.
