Check if a value exists in a cell array starting from a value whose index is the desired value
Mostra commenti meno recenti
Let's suppose:
A={5, 15, 0, [11, 7], 9, 0, [1, 20, 21], 18, [22,15], 0, 16, [13, 14], 17, 4, 6 };
a=6; b=1;
Now, I would like to know if I can get to b from a using the values as an index. In this case:
Value Index
6 -> 15
15 -> [2, 9]
for
2 -> Nan
9 -> 5
and
5 -> 1
Thanks
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Resizing and Reshaping Matrices in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!