Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main() {
- int h, u, d;
- cin >> h >> u >> d;
- int denovi = 1;
- for(int zhelka = 0; zhelka + u < h; zhelka += u) {
- denovi += 1;
- zhelka -= d;
- }
- cout << denovi << endl;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement