In Matlab I have given a list of indices (e.g. a = [2 7]) and values (e.g. b = [123 642]. I need a function f which returns a vector (c) with the values at the given the indices and zeros inbetween.
so: c = [0 123 0 0 0 0 642]
How can I perform this task?
regards,
Vcent