#include using namespace std; int main() { int p,d,m,s; cin >> p >> d >> m >> s; int sum=0; int c = 0; while(true){ s -= p; p = max(p-d,m); if(s >= 0) ++c; else break; } cout << c; return 0; }