Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main()
- {
- int n;
- int covecki_godini = 0;
- cin >> n;
- for (int i = 0; i <= n; i += 1)
- {
- if (i == 1)
- {
- covecki_godini += 15;
- }
- if (i == 2)
- {
- covecki_godini += 9;
- }
- if (i >= 3 and i <=6)
- {
- covecki_godini += 4;
- }
- if (i > 6)
- {
- covecki_godini += 5;
- }
- }
- cout << covecki_godini << endl;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement