How to attach the element into correct index

1 次查看(过去 30 天)
I HAVE VECTOR A = [0,540]
B = [60,600,15]
how to attach B(3) as A(3) ? //output should be A = [0,540,15]
how to attach B(1) as A(1) ? //output should be A = [60,600,15]

回答(1 个)

Fangjun Jiang
Fangjun Jiang 2018-5-25
编辑:Fangjun Jiang 2018-5-25
A=[A,B(3)]
A(1,:)=B(1,:)

类别

Help CenterFile Exchange 中查找有关 Matrix Indexing 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by