how to input values in a 2D matrix using a nested for loop of size 5*5?

12 次查看(过去 30 天)
how to input values in a 2-D matrix using a nested for loop of size 5*5?

采纳的回答

Thorsten
Thorsten 2015-12-3
编辑:Thorsten 2015-12-3
for i = 1:5
for j = 1:5
A(i,j) = input(sprintf('please enter value (%d, %d) >> ', i, j))
end
end

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Multidimensional Arrays 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by