#include <stdio.h>
int main(){
float price = 0;
int month, day, hasP = 0;
scanf("%f %d %d %d", &price, &month, &day, &hasP);
float cut = 0;
if(month == 11 && day == 11){
cut = 0.7;
}else if(month == 12 && day == 12){
cut = 0.8;
}
float pay = price*cut - 50*hasP;
if(pay <= 0){
printf("0.00");
}else{
printf("%.2f", pay);
}
}
int main(){
float price = 0;
int month, day, hasP = 0;
scanf("%f %d %d %d", &price, &month, &day, &hasP);
float cut = 0;
if(month == 11 && day == 11){
cut = 0.7;
}else if(month == 12 && day == 12){
cut = 0.8;
}
float pay = price*cut - 50*hasP;
if(pay <= 0){
printf("0.00");
}else{
printf("%.2f", pay);
}
}
2020-11-05
在牛客打卡8天,今天学习:刷题 5 道/代码提交 6 次
全部评论
相关推荐
沉淀小子:干啥都不丢人啊,生存是必须要的,销售很考验一个人综合素质能力的,好的销售人脉和资源可不比写字楼的白领差啊 点赞 评论 收藏
分享
02-09 20:08
山东大学 组织发展
SHC2:春招先狠狠投递,然后你看看能不能申请香港新加坡的一年制master,花不了多少钱,或者现在赶紧去刷一段实习。HR专业考研没必要 点赞 评论 收藏
分享
蔚来公司氛围 619人发布