function ubvec3 = ubvec_xor ( n, ubvec1, ubvec2 )

%*****************************************************************************80
%
%% ubvec_xor() computes the exclusive OR of two UBVEC's.
%
%  Discussion:
%
%    A UBVEC is an integer vector of binary digits, intended to
%    represent a nonnegative integer.  BVEC(1) is the units digit, BVEC(N)
%    is the coefficient of 2^(N-1).
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    19 November 2015
%
%  Author:
%
%    John Burkardt
%
%  Input:
%
%    integer N, the length of the vectors.
%
%    integer UBVEC1(N), UBVEC2(N), the binary vectors to be XOR'ed.
%
%    integer UBVEC3(N), the exclusive OR of the two vectors.
%
  ubvec3(1:n) = mod ( ubvec1(1:n) + ubvec2(1:n), 2 );

  return
end
