double price = 0; int month = 0; int day = 0; int flag = 0; double sum = 0; scanf("%lf %d %d %d",&price,&month,&day,&flag); if (price > 50) { if ((month == 12 && day == 12)) { sum = price * 0.8 - 50 * flag; if (sum > 0) printf("%.2lf", sum); else printf("0.00\n"); } else if ((month == 11 && day == 11)) { sum = price * 0.7 - 50 * flag; if (sum > 0) printf("%.2lf", sum); else printf("0.00\n"); } else printf("%.2lf",price); } else printf("0.00\n"); return 0; }