#include <cstdio>
#include <cstring>
#include <cmath>
int main(){
	int a, n, b, c;
	scanf("%d",&n);
	a = 0;
	b = 1;
	c = 0;
	for(a = 0; a < n; c++)
	{
		a = a + b;
		b++;
	}
		printf("%d",c);
	return 0;
}