#2862
code
av_timer 3 ms
memory 256 KiB
access_time 2018-01-20 21:27:53
face Jared
#include<cstdio>
#include<climits>
#include<cstring>

using namespace std;


int main()
{
	int n;
	while(~scanf("%d",&n)&&n){
		int s[101];
		memset(s,0,sizeof(s));
		for(int i=0;i<n;i++){
			int x;
			scanf("%d",&x);
			s[x]++;
		}
		int y;
		scanf("%d",&y);
		printf("%d\n",s[y]);
	}
	return 0;
}