Dotcpp  >  编程题库  >  First Blood
题目 1421:

First Blood

时间限制: 1s 内存限制: 128MB 提交: 175 解决: 74

题目描述

We always call the first kill in the Dota First Blood, and in the ACM-ICPC, we also call the first AC First Blood.
We all like First Blood, but it need some luck and care.
NOW, COME ON!!! TYPE ON YOUR KEYBOARD!!!! Maybe the First Blood is YOURS!!!

输入格式

There are multiple test cases.
Each test case begins with a line of two integers n and m (0<n<=1000,0<m<2147483648).
The next line consists of n integers a[1] ... a[n], and for i between 1 and n, 0<a[i]<2147483648.
A test case with n=0 terminates the input and this test case is not to be processed.

输出格式

Your task is to count how many numbers in those n integers that not smaller than m, and output the number.

样例输入

10 4
1 2 3 4 5 6 7 8 9 0
0

样例输出

6

提示

零基础的同学可以先学习基础,教程见:  C语言教程C++教程编译器教程数据结构教程Python教程单片机教程

视频教学见视频网课

标签