Why is my code not working?
显示 更早的评论
How can I get it to display the message if the x meets the requirements?
Code
input('Enter a test grade between 0 and 100: ')
if (x >= 90)
disp('The student earned an A.')
elseif (x >= 65)
disp(The student passed the test_11)
else
disp('The student did not pass the test.')
end
I get this error
Invalid expression. Check for missing multiplication operator, missing or unbalanced
delimiters, or other syntax error. To construct matrices, use brackets instead of
parentheses.
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Testing Frameworks 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!