MATLAB: Rapid Vector Matching/Search Problem

computational speedpatternsearch

I have a matrix (we'll call A) of size m x n, and a vector (we'll call B) that is a 1 x n, and I am interested in finding the one unique index (and I know there is just one) where A(index,:) equals B, is there a way for me to quickly make the determination in MATLAB besides using the following code:
      for i = 1 : m          if ((isequal(A(i,:), B)))              indexIntrest = i;              break;          end      end
Thanks

 found_row = ismember(A,B,'rows')
 A= randi(2,100,4); indexIntrest=find(ismember(A,[ 2 1 1 1],'rows'))