Limak is going to participate in a contest on the last day of the 2016. The contest will start at 20:00 and will last four hours, exactly until midnight. There will be n problems, sorted by difficulty, i.e. problem 1 is the easiest and problem n is the hardest. Limak knows it will take him 5·i minutes to solve the i-th problem.

Limak's friends organize a New Year's Eve party and Limak wants to be there at midnight or earlier. He needs k minutes to get there from his house, where he will participate in the contest first.

How many problems can Limak solve if he wants to make it to the party?


-----Input-----

The only line of the input contains two integers n and k (1 ≤ n ≤ 10, 1 ≤ k ≤ 240) — the number of the problems in the contest and the number of minutes Limak needs to get to the party from his house.


-----Output-----

Print one integer, denoting the maximum possible number of problems Limak can solve so that he could get to the party at midnight or earlier.


-----Examples-----
Input
3 222

Output
2

Input
4 190

Output
4

Input
7 1

Output
7



-----Note-----

In the first sample, there are 3 problems and Limak needs 222 minutes to get to the party. The three problems require 5, 10 and 15 minutes respectively. Limak can spend 5 + 10 = 15 minutes to solve first two problems. Then, at 20:15 he can leave his house to get to the party at 23:57 (after 222 minutes). In this scenario Limak would solve 2 problems. He doesn't have enough time to solve 3 problems so the answer is 2.

In the second sample, Limak can solve all 4 problems in 5 + 10 + 15 + 20 = 50 minutes. At 20:50 he will leave the house and go to the party. He will get there exactly at midnight.

In the third sample, Limak needs only 1 minute to get to the party. He has enough time to solve all 7 problems.

Difficulty: interview

Starter code:

Solutions:
"""
Codeforces Good Bye 2016 Contest Problem A

Author  : chaotic_iak
Language: Python 3.5.2
"""

################################################### SOLUTION

def main():
    n,k = read()
    avail = 240-k
    i = 1
    while i <= n and avail >= 5*i:
        avail -= 5*i
        i += 1
    print(i-1)

#################################################### HELPERS

def read(callback=int):
    return list(map(callback, input().strip().split()))

def write(value, end="\n"):
    if value is None: return
    try:
        value = " ".join(map(str, value))
    except:
        pass
    print(value, end=end)

write(main())


n, k = map(int, input().split())

t = 0
k = 240 - k

for j in range(n + 1):
    t += 5 * j
    if t > k:
        print(j - 1)
        break
else:
    print(j)

ans = 0
t = 4*60
n,k = map(int,input().split())
for j in range(n):
    t -= 5*(j+1)
    if t >= k:
        ans +=1
        
    else:
        break
print(ans)

tm = 240
n, k = map(int, input().split())
tm -= k
ans = 0
for i in range(1, n + 1):
	tm -= 5 * i
	if tm < 0:
		break
	ans += 1
print(ans)

n, k = map(int, input().split())

current = 0
for i in range(1, n + 1):
    current += 5 * i
    if 60 * 4 - current - k < 0:
        print(i - 1)
        return
print(n)

n, k = list(map(int, input().split()))
a = 0
ind = 0
while (a <= 240 - k and ind <= n):
    a += ind * 5 + 5
    ind += 1
a -= ind * 5
print(ind - 1)


read = lambda: list(map(int, input().split()))
n, k = read()
t = 240 - k
cur = 0
for i in range(1, n + 1):
    c = 5 * i
    if cur + c > t:
        ans = i - 1
        break
    cur += c
else:
    ans = n
print(ans)


n, k = map(int, input().split())
s = 0
cnt = 0
for i in range(1, n + 1):
  if s + 5 * i <= 240 - k:
    s += 5 * i
    cnt += 1
print(cnt)

n, k = list(map(int, input().split()))
ans = 0
curr = 0
while curr + 5 * (ans + 1) + k <= 240:
    ans += 1
    curr += 5 * ans
print(min(n, ans))

#!/usr/bin/env python3

def main():
    try:
        while True:
            n, k = list(map(int, input().split()))
            time = 240 - k
            result = 0
            for i in range(1, n + 1):
                if time < 5 * i:
                    break
                time -= 5 * i
                result += 1

            print(result)

    except EOFError:
        pass

main()


def main():
    n, k = list(map(int, input().split()))
    t = k
    for i in range(n + 1):
        t += 5 * (i + 1)
        if t > 240:
            print(i)
            return
    print(n)

 
def __starting_point():
    main()

__starting_point()

n, m = list(map(int, input().split()))
t = 4 * 60 - m
o = 0
a = 5
otv = 0
while o + a <= t and otv < n:
    o += a
    a += 5
    otv += 1
print(otv)


n, k = list(map(int, input().split()))

rem = 240
rem -= k

z = 5
ans = 0

while n > 0 and rem - z >= 0:
    rem -= z
    ans += 1
    n -= 1
    z += 5

print(ans)


n, k = list(map(int, input().split()))
t = 4 * 60 - k
i = 1
while i <= n and t >= 5 * i:
    t -= 5 * i
    i += 1
i -= 1
print(i)



def r():
	return list(map(int, input().split()))
n, k = r()
m = 240
count = 0
for i in range(1, n + 1):
	if 5 * i + k > m:
		break
	count += 1
	k += 5 * i
print(count)

n,k=[int(i) for i in input().split()]
t=(240-k)//5
i=0
while i+1<=t:
    i+=1
    t-=i
print(min(i,n))


n, k = list(map(int, input().split()))
t = 240 - k
s = 0
for i in range(1, n+1):
    if t < 0:
        print(s-1)
        break
    s += 1
    t -= 5*i
else:
    if t < 0:
        print(s-1)
    else:
        print(s)


n, k = list(map(int, input().split()))
time = 240
counter = 0
summ = 0
while counter < n:
    if k + 5 * (counter + 1) + summ <= 240:
        counter += 1
        summ += 5 * (counter)
    else:
        break
print(counter)

n, k = list(map(int, input().split()))
res = 0
cur = 60 * 4
for i in range(1, n + 1):
    if cur - 5 * i >= k:
        res += 1
        cur -= 5 * i
    else:
        break
print(res)


n, m = map(int, input().split())
l = 240 - m
ss = []
x = [i * 5 + 5 for i in range(n)]
for i in range(n + 1):
    if (sum(x[:i]) <= l):
        ss.append(i)
print(max(ss))

'''
Created on 30 dec. 2016

@author: Moldovan
'''
from sys import stdout

n,k=input().split()
n = int(n)
k = int(k)
problems = 0
total = 60*4 - k
for i in range(n):
    if total >= 5*(i+1):
        problems = problems +1
        total = total - 5*(i+1)
        
print(problems) 


from itertools import permutations

n, k = list(map(int, input().split()))
ans = 0
cur = 4 * 60 - k
for i in range(1, n + 1):
    if cur < 5 * i:
        break
    cur -= 5 * i
    ans += 1

print(ans)


n,k=list(map(int,input().split()))
t=240-k
count=0
for i in range(1,n+1):
    if t-5*i>=0:
        t=t-5*i
        count+=1
print(count)


n, k = list(map(int, input().split()))

limit = 4 * 60 - k

for i in range(1, n+1):
    limit -= i * 5
    if limit < 0:
        print(i - 1)
        break
else:
    print(n)


n, k = list(map(int, input().split()))
t = 240 - k
cur = 0
ans = 0
for i in range(1,n + 1):
    cur += i * 5
    if (cur > t):
        break
    ans += 1
print(ans)