Matlab 中disp 的问题

[复制链接]
查看11 | 回复2 | 2012-11-24 09:22:21 | 显示全部楼层 |阅读模式
num=input('enter a number:'); a=fix(num/10); % a 需要是正整数才能判断switch a
% switch 的格式要真确
case 10
disp('优秀');
case 9
disp('优秀') ;
case 8
disp('良好');
case 7
disp('及格');
otherwise
disp('不及格')end...
回复

使用道具 举报

千问 | 2012-11-24 09:22:21 | 显示全部楼层
a=floor(num/10);...
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行