Info
La pregunta está cerrada. Vuélvala a abrir para editarla o responderla.
hi,i am getting error as not enough input arguments,while i run the below code....?? please let me know that?(the error is in second line of code)
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
Raghu dharahas reddy kotla
el 8 de Dic. de 2019
Cerrada: MATLAB Answer Bot
el 20 de Ag. de 2021
function [x]=trio(m,n)
x=rand([3*m n]);
x(1:3*m/3,:)=1;
x(3*m/3+1:3*m/3+m,:)=2;
x(3*m/3+m+1:end,:)=3;
end
1 comentario
dpb
el 8 de Dic. de 2019
Works fine here. Show us how you called it.
NB: 3*m/3 --> m so the above could be more succinctly written as
function [x]=trio(m,n)
x=rand([3*m n]);
x(1:m,:)=1;
x(m+1:2*m,:)=2;
x(2*m+1:end,:)=3;
end
Ver también
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!