#abc356b. B - Nutrients
B - Nutrients
Score : points
问题陈述
高桥非常注重健康,并且关心他是否从饮食中获得了足够的种营养素。
对于第种营养素,他的目标是每天至少摄入单位。
今天,他吃了种食物,从第种食物中,他摄入了单位的第种营养素。
确定他是否达到了所有种营养素的目标。
以上为大语言模型 kimi 翻译,仅供参考。
Problem Statement
Takahashi is health-conscious and concerned about whether he is getting enough of types of nutrients from his diet.
For the -th nutrient, his goal is to take at least units per day.
Today, he ate foods, and from the -th food, he took units of nutrient .
Determine whether he has met the goal for all types of nutrients.
Constraints
- All input values are integers.
Input
The input is given from Standard Input in the following format:
Output
Print Yes
if the goal is met for all types of nutrients, and No
otherwise.
Sample Input 1
2 3
10 20 30
20 0 10
0 100 100
Sample Output 1
Yes
For nutrient , Takahashi took units from the -st food and units from the -nd food, totaling units, thus meeting the goal of taking at least units.
Similarly, he meets the goal for nutrients and .
Sample Input 2
2 4
10 20 30 40
20 0 10 30
0 100 100 0
Sample Output 2
No
The goal is not met for nutrient .