matlab 这个函数哪里出错了fuction [ou1,ou2]=xuhaoyi(in1,in2,in3)%mytest is used to do the question% Purpose:If input1 is between 60 and 70 and input2 is between 20 and 25 and input3 is above 90,% then output1 is true and output 2 is 1.% If in
来源:学生作业帮助网 编辑:作业帮 时间:2024/07/16 19:01:49
![matlab 这个函数哪里出错了fuction [ou1,ou2]=xuhaoyi(in1,in2,in3)%mytest is used to do the question% Purpose:If input1 is between 60 and 70 and input2 is between 20 and 25 and input3 is above 90,% then output1 is true and output 2 is 1.% If in](/uploads/image/z/2686181-5-1.jpg?t=matlab+%E8%BF%99%E4%B8%AA%E5%87%BD%E6%95%B0%E5%93%AA%E9%87%8C%E5%87%BA%E9%94%99%E4%BA%86fuction+%5Bou1%2Cou2%5D%3Dxuhaoyi%28in1%2Cin2%2Cin3%29%25mytest+is+used+to+do+the+question%25+Purpose%3AIf+input1+is+between+60+and+70+and+input2+is+between+20+and+25+and+input3+is+above+90%2C%25+then+output1+is+true+and+output+2+is+1.%25+If+in)
matlab 这个函数哪里出错了fuction [ou1,ou2]=xuhaoyi(in1,in2,in3)%mytest is used to do the question% Purpose:If input1 is between 60 and 70 and input2 is between 20 and 25 and input3 is above 90,% then output1 is true and output 2 is 1.% If in
matlab 这个函数哪里出错了
fuction [ou1,ou2]=xuhaoyi(in1,in2,in3)
%mytest is used to do the question
% Purpose:If input1 is between 60 and 70 and input2 is between 20 and 25 and input3 is above 90,% then output1 is true and output 2 is 1.
% If input1 is between 65 and 75,and input2 is between 25 and 30 and input3 is above 80,then % output1 is true and output 2 is 0.
% Otherwise input1 is false and output2 is 0.
% Define the variables:
% msg -- error message
%
% Do the question
if in1=60 & in2>=20 && in290
ou1=1; ou2=1;
elseif in1=65 & in2>=25 && in280
ou1=1; ou2=0;
else
ou1=0; ou2=0
end
这个自定义的函数哪里出现了错误?
matlab 这个函数哪里出错了fuction [ou1,ou2]=xuhaoyi(in1,in2,in3)%mytest is used to do the question% Purpose:If input1 is between 60 and 70 and input2 is between 20 and 25 and input3 is above 90,% then output1 is true and output 2 is 1.% If in
if in1=60 && in2>=20 && in290
ou1=1; ou2=1;
elseif in1=65 && in2>=25 && in280
ou1=1; ou2=0;
else
ou1=0; ou2=0
end