find same elements between two sequences

a=[2 5 4 6 6 7 9 8 4 5 61 2 56 41]
b=[1 9 7 3 2 4 5 1 6 4 78 1 12 56 14 27 46 1 3 2 4]
how to find same elements in between two sequences. in above 2,4,5,6,7,9,56 are same elements.

回答 (1 件)

Azzi Abdelmalek
Azzi Abdelmalek 2016 年 12 月 30 日

0 投票

a=[2 5 4 6 6 7 9 8 4 5 61 2 56 41]
b=[1 9 7 3 2 4 5 1 6 4 78 1 12 56 14 27 46 1 3 2 4]
c=intersect(a,b)

カテゴリ

ヘルプ センター および File ExchangeSignal Processing Toolbox についてさらに検索

質問済み:

2016 年 12 月 30 日

回答済み:

2016 年 12 月 30 日

Community Treasure Hunt

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

Start Hunting!

Translated by