width=input('enter the width of the box') height =input('enter the height of the box') for ii = 1:height for jj=1:ii if mod(jj,2)==0 fprintf('*') else fprintf('b') end end fprintf('\n') for jj =1 : width fprintf('x') end fprintf('\n') end