Dim nums(9) as Integer,max as Integer,i as Integer
max=nums(0)
For i=1 to 9
If nums(i)>max then max=nums(i)
next i
Print max
把十個數放在數組nums[]中
#include "iostream.h"
int nums[9],i,max=nums[0];
for(i=1,i<=9,i++)
{
if(nums[i]>max)
max=nums[i];
}
cout<<max;
直接寫的代碼,沒經過測試呢,不好意思哈