#11419: why I am wrong?


warren (warren(爽啦))


#include <iostream>
using namespace std;
/* run this program using the console pauser or add your own getch, system("pause") or input loop */
int main(int argc, char** argv) {
 
 int x;
 cout <<"score:";
 cin >>x;
 
   if((x>=0)&&(x<=10))
     cout << x*6 <<endl;
   if((x>=11)&&(x<=20))
     cout << 60+(x-10)*2<<endl ;
   if((x>=21)&&(x<=40))
     cout << 80+(x-20)<<endl ;
   if(x>40)
     cout << 100<<endl ;
 
 
 
 
 
 return 0;
}
#11420: Re:why I am wrong?


simon3871 (simon3871)


cout <<"score:";

這行刪掉就可以了