function val = mymax2_good(x, y) 
% mymax2_good Demonstration routine to illustrate value-return mechanism [PHYS210-DEMO]
%  This implementation of 2-argument max function is CORRECT.  It DOES 
%  assign the output argument, val, prior to returning.  
%
%  See mymax2_bad for an incorrect implementation.
   if x > y
      val = x;
   else
      val = y;
   end
end
