我的筆記小屋。
int income,temp; float tax; printf("Please enter income >"); scanf("%d",&income); temp=(income/1000); switch(temp) { case 0: tax=income*0.2; break; case 1: tax=income*0.3; break; default: tax=income*0.4; } printf("Tax is %.2f\n",tax);
沒有留言:
張貼留言