Info

La pregunta está cerrada. Vuélvala a abrir para editarla o responderla.

How can I obtain another vector for a known vector, such that the elements of the new vector are the time that the element at the corresponding position in the known vector appears in it, without using loops?

1 visualización (últimos 30 días)
For example, if A=[1 2 3 4 5 6], then B=[1 1 1 1 1 1]; if A=[1 1 2 2 3 3], then B=[1 2 1 2 1 2]; if A=[1 1 1 3 4 3], then B=[1 2 3 1 1 2]; ...and so on. I'd like to fulfil this without using loops.

Respuestas (0)

La pregunta está cerrada.

Community Treasure Hunt

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

Start Hunting!