matrix 1xn MatLab

1 vue (au cours des 30 derniers jours)
Takim Mustakim
Takim Mustakim le 8 Nov 2022
Modifié(e) : Arif Hoq le 8 Nov 2022
a = [0 0 0 0 0 0 0 0 0 0];
b = [1 2 3];
how to make: c = [1 2 3 0 0 0 0 0 0 0]; from a and b

Réponse acceptée

Arif Hoq
Arif Hoq le 8 Nov 2022
Modifié(e) : Arif Hoq le 8 Nov 2022
a = [0 0 0 0 0 0 0 0 0 0];
b = [1 2 3];
a(1:length(b))=b;
c=a
c = 1×10
1 2 3 0 0 0 0 0 0 0

Plus de réponses (0)

Catégories

En savoir plus sur Resizing and Reshaping Matrices dans Help Center et File Exchange

Produits


Version

R2021a

Community Treasure Hunt

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

Start Hunting!

Translated by