X = int(eval(input()))



for i in range(1,X+1):

  if((i*(i+1))/2 >= X):

    print(i)

    break
import sys



stdin = sys.stdin



ns = lambda : stdin.readline().rstrip()

na = lambda : list(map(int, stdin.readline().split()))

ni = lambda : int(ns())

def main():

  n = ni()

  f = lambda x: (x * (x+1)) // 2

  for i in range(1, n+1):

    if (f(i) >= n):

      print(i)

      return

main()
X = int(eval(input()))
for i in range(1, X + 1):
    if (i * (i + 1)) / 2 >= X:
        print(i)
        break

import sys

stdin = sys.stdin
ns = lambda: stdin.readline().rstrip()
na = lambda: list(map(int, stdin.readline().split()))
ni = lambda: int(ns())


def main():
    n = ni()
    f = lambda x: (x * (x + 1)) // 2
    for i in range(1, n + 1):
        if f(i) >= n:
            print(i)
            return


main()

-X = int(eval(input())) -for i in range(1, X + 1): -    if (i * (i + 1)) / 2 >= X: -        print(i) -        break +import sys + +stdin = sys.stdin +ns = lambda: stdin.readline().rstrip() +na = lambda: list(map(int, stdin.readline().split())) +ni = lambda: int(ns()) + + +def main(): +    n = ni() +    f = lambda x: (x * (x + 1)) // 2 +    for i in range(1, n + 1): +        if f(i) >= n: +            print(i) +            return + + +main()