how do i find common elements without using the following?

1 view (last 30 days)
i need to find common elements in to arrays without using loops, intersect or ismember. any ideas?

Answers (1)

Matt J
Matt J on 18 Nov 2014
Edited: Matt J on 18 Nov 2014
As a hint, bsxfun() might be useful.
arrayfun() might also let you do this, but I'm not sure that it counts as "loop-free", since it is basically just a wrapper for a for-loop.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!