#include <stdio.h> int main() { double price; int month; int day; int paper; scanf("%lf %d %d %d", &price, &month, &day, &paper); if (month == 11 && day ==11) { price *= 0.7; } else if((month == 12 && day ==12)) { price *= 0.8; } if(paper == 1) { price -= 50; } if (price < 0) { printf("0.00...