Finding common elements in an array (even if they are not in the same position)
3 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
cgo
el 21 de Jul. de 2022
Respondida: Matt J
el 21 de Jul. de 2022
I have two vectors a and b. Both vectors may not be of the same length. I want to find the common elements between these vectors. For example, if the number 1 appears in both vectors a and b, then i should output 1 and all other common elements.
I am struggling to think of how to do this. Any insights? Thanks
0 comentarios
Respuesta aceptada
Más respuestas (0)
Ver también
Categorías
Más información sobre Multidimensional Arrays en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!