#include <bits/stdc++.h>
using namespace std;
double pi = 3.141592653589793238462643;
long double ee = 2.7182818284590452353602875;
int nod(int a, int b) {
  int c;
  while (b) {
    c = a % b;
    a = b;
    b = c;
  }
  return a;
}
int nok(int a, int b) {
  int c;
  int q = a, w = b;
  while (b) {
    c = a % b;
    a = b;
    b = c;
  }
  return q * w / a;
}
int main() {
  int n, q = 0, w = 0;
  cin >> n;
  for (int i = 1; i < n + 1; i++)
    if (w < i) {
      w = w + i;
      q++;
    }
  cout << q;
}
