#include typedef unsigned long long ull;int f(ull m) { ull sum = 0; for (int n = 1;; n++) { sum += n * n * (3 * n + 1) / 2; if (sum >= m) return n; } }int main(void) { ull m; scanf("%llu", &m); printf("%d\n", f(m)); return 0;}