clear all;clc;x=rand(1,10) n=length(x);for i=1:n-1for j=1:n-iif x(j)>x(j+1)t=x(j);x(j)=x(j+1);x(j+1)=t;endendendx