code: def size(a, b=0, nargout=1):
      
      s = np.asarray(a).shape
      if s is ():
          return 1 if b else (1,)*nargout
      # a is not a scalar
      try:
          if b:
              return s[b-1]
          else:
              return matlabarray(s) if nargout <= 1 else s
      except IndexError:
          return 1
docs: >>> size(zeros(3,3)) + 1
      matlabarray([[4, 4]])