Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main() {
- string year;
- cin >> year;
- double p, h;
- cin >> p >> h;
- double game = ((48 - h) * 3 / 4) + h + p * 2 / 3;
- if (year == "leap") {
- game *= 1.15;
- }
- cout << (int)game << endl;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement