MATLAB Answers

0

Array Operation with using another array

Asked by Afiye Havva Geçgel on 29 May 2019
Latest activity Answered by Kevin Phung on 29 May 2019
I have 2 different arrays as
k=[4 9 3 3 6 8 8 12 6]
m=[1 2 6 7]
i need to reach the summation of
k(1)+k(2)+k(6)+k(7)
how can i do this with for loop?

  0 Comments

Sign in to comment.

1 Answer

Answer by Kevin Phung on 29 May 2019
 Accepted Answer

sum(k(m))

  0 Comments

Sign in to comment.