{"raw_statement":[{"iden":"statement","content":"We often go to supermarkets to buy some fruits or vegetables, and on the tag there prints the price for a kilo. But in some supermarkets, when asked how much the items are, the clerk will say that $a$ _yuan_ for $b$ kilos (You don't need to care about what _\"yuan\"_ is), the same as $a/b$ _yuan_ for a kilo.\n\nNow imagine you'd like to buy $m$ kilos of apples. You've asked $n$ supermarkets and got the prices. Find the minimum cost for those apples.\n\nYou can assume that there are enough apples in all supermarkets."},{"iden":"input","content":"The first line contains two positive integers $n$ and $m$ ($1 \\leq n \\leq 5\\,000$, $1 \\leq m \\leq 100$), denoting that there are $n$ supermarkets and you want to buy $m$ kilos of apples.\n\nThe following $n$ lines describe the information of the supermarkets. Each line contains two positive integers $a, b$ ($1 \\leq a, b \\leq 100$), denoting that in this supermarket, you are supposed to pay $a$ _yuan_ for $b$ kilos of apples."},{"iden":"output","content":"The only line, denoting the minimum cost for $m$ kilos of apples. Please make sure that the absolute or relative error between your answer and the correct answer won't exceed $10^{-6}$.\n\nFormally, let your answer be $x$, and the jury's answer be $y$. Your answer is considered correct if $\\frac{|x - y|}{\\max{(1, |y|)}} \\le 10^{-6}$."},{"iden":"examples","content":"Input\n\n3 5\n1 2\n3 4\n1 3\n\nOutput\n\n1.66666667\n\nInput\n\n2 1\n99 100\n98 99\n\nOutput\n\n0.98989899"},{"iden":"note","content":"In the first sample, you are supposed to buy $5$ kilos of apples in supermarket $3$. The cost is $5/3$ _yuan_.\n\nIn the second sample, you are supposed to buy $1$ kilo of apples in supermarket $2$. The cost is $98/99$ _yuan_."}],"translated_statement":[{"iden":"statement","content":"我们经常去超市购买水果或蔬菜，标签上会印出每千克的价格。但在一些超市，当被问及商品价格时，店员会说：买 $b$ 千克需要支付 $a$ _元_（你无需关心 _\"元\"_ 是什么），这等价于每千克 $a \\/ b$ _元_。\n\n现在假设你想购买 $m$ 千克的苹果。你询问了 $n$ 家超市并获得了它们的价格。请找出购买这些苹果的最低成本。\n\n你可以假设所有超市的苹果供应充足。\n\n第一行包含两个正整数 $n$ 和 $m$（$1 lt.eq n lt.eq 5 thin 000$，$1 lt.eq m lt.eq 100$），表示有 $n$ 家超市，你想要购买 $m$ 千克的苹果。\n\n接下来的 $n$ 行描述了各超市的信息。每行包含两个正整数 $a, b$（$1 lt.eq a, b lt.eq 100$），表示在该超市，你需要支付 $a$ _元_ 来购买 $b$ 千克的苹果。\n\n仅输出一行，表示购买 $m$ 千克苹果的最低成本。请确保你的答案与正确答案的绝对误差或相对误差不超过 $10^(-6)$。\n\n形式化地，设你的答案为 $x$，标准答案为 $y$。若满足 $frac(| x -y |, max (1 comma | y |)) lt.eq 10^(-6)$，则你的答案被视为正确。\n\n在第一个样例中，你应在第 $3$ 家超市购买 $5$ 千克苹果，成本为 $5 \\/ 3$ _元_。\n\n在第二个样例中，你应在第 $2$ 家超市购买 $1$ 千克苹果，成本为 $98 \\/ 99$ _元_。\n"},{"iden":"input","content":"第一行包含两个正整数 $n$ 和 $m$（$1 lt.eq n lt.eq 5 thin 000$，$1 lt.eq m lt.eq 100$），表示有 $n$ 家超市，你想要购买 $m$ 千克的苹果。接下来的 $n$ 行描述了各超市的信息。每行包含两个正整数 $a, b$（$1 lt.eq a, b lt.eq 100$），表示在该超市，你需要支付 $a$ _元_ 来购买 $b$ 千克的苹果。"},{"iden":"output","content":"仅输出一行，表示购买 $m$ 千克苹果的最低成本。请确保你的答案与正确答案的绝对误差或相对误差不超过 $10^(-6)$。形式化地，设你的答案为 $x$，标准答案为 $y$。若满足 $frac(| x -y |, max (1 comma | y |)) lt.eq 10^(-6)$，则你的答案被视为正确。"},{"iden":"examples","content":"输入\n3 5\n1 2\n3 4\n1 3\n输出\n1.66666667\n\n输入\n2 1\n99 100\n98 99\n输出\n0.98989899"},{"iden":"note","content":"在第一个样例中，你应在第 $3$ 家超市购买 $5$ 千克苹果，成本为 $5 \\/ 3$ _元_。在第二个样例中，你应在第 $2$ 家超市购买 $1$ 千克苹果，成本为 $98 \\/ 99$ _元_。"}],"sample_group":[],"show_order":[],"formal_statement":"**Definitions**  \nLet $ n, m \\in \\mathbb{Z}^+ $ denote the number of supermarkets and the desired quantity of apples (in kilos), respectively.  \nFor each supermarket $ i \\in \\{1, \\dots, n\\} $, let $ (a_i, b_i) \\in \\mathbb{Z}^+ \\times \\mathbb{Z}^+ $ denote the price $ a_i $ yuan for $ b_i $ kilos of apples.\n\n**Constraints**  \n1. $ 1 \\le n \\le 5000 $  \n2. $ 1 \\le m \\le 100 $  \n3. $ 1 \\le a_i, b_i \\le 100 $ for all $ i \\in \\{1, \\dots, n\\} $\n\n**Objective**  \nCompute the minimum cost to buy $ m $ kilos of apples, where the cost per kilo at supermarket $ i $ is $ \\frac{a_i}{b_i} $.  \nThe minimum total cost is:  \n$$\n\\min_{i \\in \\{1, \\dots, n\\}} \\left( \\frac{a_i}{b_i} \\cdot m \\right)\n$$","simple_statement":null,"has_page_source":false}