100 atcoder#ABC161B. [ABC161B] Popular Vote
[ABC161B] Popular Vote
Score : points
Problem Statement
We have held a popularity poll for items on sale. Item received votes.
From these items, we will select as popular items. However, we cannot select an item with less than of the total number of votes.
If popular items can be selected, print Yes
; otherwise, print No
.
Constraints
- are distinct.
- All values in input are integers.
Input
Input is given from Standard Input in the following format:
Output
If popular items can be selected, print Yes
; otherwise, print No
.
4 1
5 4 2 1
Yes
There were votes in total. The most popular item received votes, and we can select it.
3 2
380 19 1
No
There were votes in total. The second and third most popular items received less than of the total number of votes, so we cannot select them. Thus, we cannot select two popular items.
12 3
4 56 78 901 2 345 67 890 123 45 6 789
Yes