Problem2256--Counting 2

2256: Counting 2

[Creator : ]
Time Limit : 1.000 sec  Memory Limit : 128 MB

Description

Time Limit: 2 sec / Memory Limit: 1024 MB

Score : 300300 points

Problem Statement

There is a class with NN students. The height of the ii-th student (1 \leq i \leq N)(1iN) is A_iAi.
For each j=1,2,\ldots,Qj=1,2,,Q, answer the following question.
  • How many of the NN students have a height of at least x_jxj?

Constraints

  • 1 \leq N,Q \leq 2 \times 10^51N,Q2×105
  • 1 \leq A_i \leq 10^91Ai109
  • 1 \leq x_j \leq 10^91xj109
  • All values in input are integers.

Input

Input is given from Standard Input in the following format:
NNQQA_1A1A_2A2\ldotsA_NANx_1x1x_2x2\vdotsx_QxQ

Output

Print QQ lines.
The jj-th line (1 \leq j \leq Q)(1jQ) should contain the number of students with a height of at least x_jxj.

Sample Input Copy

5 5
1 2 3 4 5
6
5
4
3
2

Sample Output Copy

0
1
2
3
4

Source/Category