Taotao picked apple
[Problem description]
There is an apple tree in the yard of taotao's house. Every fall, the tree will produce 10 apples. When Apple matures, Tao will go to pick up the apple.
Tao has a bench with a height of 30 cm. When she cannot pick the apple directly with her hand, she will step on the bench and try again.
Now we know the height of 10 apples to the ground, and the maximum height that can be reached when Tao's handles are stretched. Please help Tao calculate the number of apples She can pick.
If she encounters an apple, the apple will fall.
[Input file]
The input file apple. In contains two rows of data. The first line contains 10 integers (in centimeters) between 100 and 200 (including 100 and 200)
Represents the height of 10 apples to the ground, and two adjacent integers are separated by a space.
The second row only contains an integer (in centimeters) between 100 and 120 (including 100 and 120), which indicates the maximum height that can be reached when the tao handles straighten.
[Output file]
The output file "apple. Out" contains one row. This row contains only one integer, indicating the number of apples that Tao can extract.
[Example input]
100 200 150 140 129 134 167 198 200 111
110
[Sample output]
5
Import Java. io. bufferedinputstream; import Java. util. *; public class Apple {public static void main (string [] ARGs) {consumer SC = new consumer (New bufferedinputstream (system. in); string S = SC. nextline (); int n = SC. nextint (); int sum = N + 30; string STR [] = S. split ("\ s +"); int COUNT = 0; For (INT I = 0; I <Str. length; I ++) {If (integer. parseint (STR [I]) <= sum) {count ++ ;}} system. out. println (count );}}