ROHAN SUTRADHAR
Followers: 0 Following: 0
Feeds
已回答
Write a function called picker that takes three input arguments called condition, in1 and in2 in this order. The argument condition is a logical. If it is true, the function assigns the value of in1 to the output argument out, otherwise, it assigns
function out = picker(condition,in1,in2) if condition==0 out = in2; else out = in1; end
Write a function called picker that takes three input arguments called condition, in1 and in2 in this order. The argument condition is a logical. If it is true, the function assigns the value of in1 to the output argument out, otherwise, it assigns
function out = picker(condition,in1,in2) if condition==0 out = in2; else out = in1; end
4 years 前 | 0
已回答
Write a function called minimax that takes M, a matrix input argument and returns mmr, a row vector containing the absolute values of the difference between the maximum and minimum valued elements in each row. As a second output argument called mmm,
function [mmr,mmm] = minimax(A) X = A'; mmr = max(X([1:end],[1:end]))- min(X([1:end],[1:end])); mmm = max(X(:))-min(X(:)); e...
Write a function called minimax that takes M, a matrix input argument and returns mmr, a row vector containing the absolute values of the difference between the maximum and minimum valued elements in each row. As a second output argument called mmm,
function [mmr,mmm] = minimax(A) X = A'; mmr = max(X([1:end],[1:end]))- min(X([1:end],[1:end])); mmm = max(X(:))-min(X(:)); e...
4 years 前 | 0