https://www.acmicpc.net/problem/2292
n=input() n=int(n) a=1 t=1 if n==1: print(1) else: while 1: if n<a: print(t) break elif n==a: print(t) break a+=6*t t+=1