You're trying to set the record on your favorite video game. The game consists of _N_ levels, which must be completed sequentially in order to beat the game. You usually complete each level as fast as possible, but sometimes finish a level slower. Specifically, you will complete the _i_\-th level in either _F__i_ seconds or _S__i_ seconds, where _F__i_ < _S__i_, and there's a _P__i_ percent chance of completing it in _F__i_ seconds. After completing a level, you may decide to either continue the game and play the next level, or reset the game and start again from the first level. Both the decision and the action are instant.
Your goal is to complete all the levels sequentially in at most _R_ total seconds. You want to minimize the expected amount of time playing before achieving that goal. If you continue and reset optimally, how much total time can you expect to spend playing?
## Input
The first line of input contains integers _N_ and _R_ , the number of levels and number of seconds you want to complete the game in, respectively. _N_ lines follow. The _i_th such line contains integers _F__i_, _S__i_, _P__i_ (1 ≤ _F__i_ < _S__i_ ≤ 100, 80 ≤ _P__i_ ≤ 99), the fast time for level _i_, the slow time for level _i_, and the probability (as a percentage) of completing level _i_ with the fast time.
## Output
Print the total expected time. Your answer must be correct within an absolute or relative error of 10 - 9.
Formally, let your answer be _a_, and the jury's answer be _b_. Your answer will be considered correct, if .
[samples]
## Note
In the first example, you never need to reset. There's an 81% chance of completing the level in 2 seconds and a 19% chance of needing 8 seconds, both of which are within the goal time. The expected time is 0.81·2 + 0.19·8 = 3.14.
In the second example, you should reset after the first level if you complete it slowly. On average it will take 0.25 slow attempts before your first fast attempt. Then it doesn't matter whether you complete the second level fast or slow. The expected time is 0.25·30 + 20 + 0.85·3 + 0.15·9 = 31.4.
你正在尝试在你最喜欢的一款视频游戏中创造纪录。该游戏包含 #cf_span[N] 个关卡,必须按顺序依次完成才能通关。你通常会以最快的速度完成每个关卡,但有时也会较慢地完成。具体来说,你完成第 #cf_span[i] 个关卡的时间要么是 #cf_span[Fi] 秒,要么是 #cf_span[Si] 秒,其中 #cf_span[Fi < Si],并且有 #cf_span[Pi]% 的概率以 #cf_span[Fi] 秒完成。完成一个关卡后,你可以选择继续游戏并进入下一个关卡,或者重置游戏并从第一关重新开始。这两个决策和操作都是瞬时的。
你的目标是在总共不超过 #cf_span[R] 秒的时间内按顺序完成所有关卡。你希望最小化达成该目标前的期望游戏时间。如果你以最优方式决定继续或重置,你预计总共会花费多少时间?
输入的第一行包含两个整数 #cf_span[N] 和 #cf_span[R],分别表示关卡数量和你希望在多少秒内完成游戏。接下来 #cf_span[N] 行,第 #cf_span[i] 行包含三个整数 #cf_span[Fi, Si, Pi] #cf_span[(1 ≤ Fi < Si ≤ 100, 80 ≤ Pi ≤ 99)],分别表示第 #cf_span[i] 个关卡的最快时间、最慢时间,以及以最快时间完成该关卡的概率(百分比)。
请输出总期望时间。你的答案必须在绝对误差或相对误差不超过 #cf_span[10 - 9] 的范围内正确。
形式上,设你的答案为 #cf_span[a],标准答案为 #cf_span[b],当 时,你的答案将被视为正确。
在第一个例子中,你从不需要重置。有 #cf_span[81%] 的概率在 #cf_span[2] 秒内完成该关卡,有 #cf_span[19%] 的概率需要 #cf_span[8] 秒,两者均未超过目标时间。期望时间为 #cf_span[0.81·2 + 0.19·8 = 3.14]。
在第二个例子中,如果你第一关完成得较慢,你应该重置。平均而言,你需要 #cf_span[0.25] 次慢速尝试才会首次成功快速完成。之后,无论第二关是快还是慢完成都无关紧要。期望时间为 #cf_span[0.25·30 + 20 + 0.85·3 + 0.15·9 = 31.4]。
## Input
输入的第一行包含两个整数 #cf_span[N] 和 #cf_span[R],分别表示关卡数量和你希望在多少秒内完成游戏。接下来 #cf_span[N] 行,第 #cf_span[i] 行包含三个整数 #cf_span[Fi, Si, Pi] #cf_span[(1 ≤ Fi < Si ≤ 100, 80 ≤ Pi ≤ 99)],分别表示第 #cf_span[i] 个关卡的最快时间、最慢时间,以及以最快时间完成该关卡的概率(百分比)。
## Output
请输出总期望时间。你的答案必须在绝对误差或相对误差不超过 #cf_span[10 - 9] 的范围内正确。形式上,设你的答案为 #cf_span[a],标准答案为 #cf_span[b],当 时,你的答案将被视为正确。
[samples]
## Note
在第一个例子中,你从不需要重置。有 #cf_span[81%] 的概率在 #cf_span[2] 秒内完成该关卡,有 #cf_span[19%] 的概率需要 #cf_span[8] 秒,两者均未超过目标时间。期望时间为 #cf_span[0.81·2 + 0.19·8 = 3.14]。在第二个例子中,如果你第一关完成得较慢,你应该重置。平均而言,你需要 #cf_span[0.25] 次慢速尝试才会首次成功快速完成。之后,无论第二关是快还是慢完成都无关紧要。期望时间为 #cf_span[0.25·30 + 20 + 0.85·3 + 0.15·9 = 31.4]。