http://ybt.ssoier.cn:8088/problem_show.php?pid=1930
http://noi.openjudge.cn/ch0106/02/
/*
NOIP2005复赛 普及组 第一题 陶陶摘苹果
1930:【05NOIP普及组】陶陶摘苹果
http://ybt.ssoier.cn:8088/problem_show.php?pid=1930
http://noi.openjudge.cn/ch0106/02/
*/
#include<iostream>
using namespace std;
int main()
{
int b[10];
int n=0,h,i=0;
for(i=0;i<=9;i++){
cin>>b[i];
}
cin>>h;
h+=30;
for(i=0;i<=9;i++){
if(h>=b[i])n++;
}
cout<<n;
return 0;
}