Sequence is called unimodal if there exists such index that and . For the given value of find how many times it appears in array.
The first line contains the size of array and number of queries . The next line contains positive integers that represent a unimodal sequence. Each of the next lines contains value of . Numbers in array do not exceed .
For each value of print in a separate line the number of times it appears in array.