Write a fives function that will receive two arguments for the number of rows and columns, and will return a matrix with that size of all fives
belongs to book: MATLAB: A Practical Introduction to Programming and Problem Solving|Stormy Attaway|Fourth Edition| Chapter number:3| Question number:27.3
All Answers
total answers (1)
fives.m
function five = fives(r,c)
% Returns a matrix of fives of specified size
% Format of call: fives(rows, cols)
% Returns a rows by cols matrix of all fives
% Initialization
five = zeros(r,c) + 5;
end
need an explanation for this answer? contact us directly to get an explanation for this answer