function HW02P02_208117184 clc A=[5 4 1; 2 6 4; 9 6 5 ] a=size(A); t=0; A=sort(A) for i= 1:a(1) b(i,:)= sort(A(i,:)); B=[b(i,:); end

function HW02P02_208117184
clc
A=[5 4 1; 2 6 4; 9 6 5 ]
a=size(A);
t=0;
A=sort(A)
for i= 1:a(1)
b(i,:)= sort(A(i,:));
B=[b(i,:);
end
the program returns the last b(i,:) how can i save each row that results in each for loop and save them in a matrix ?

Categories

Find more on Language Fundamentals in Help Center and File Exchange

Asked:

on 5 Mar 2013

Community Treasure Hunt

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

Start Hunting!