Category

Similar Problems

0171. Funksiya6

Time limit : 1000 ms
Memory limit : 64 mb

O`lchami $n$ bo`lgan $x$ massiv va $k,m$ natural sonlar berilgan quyidagi ifodani xisoblang.


$$\frac{\displaystyle\sum_{i=1}^{m - k}x_i+\displaystyle\sum_{i=1}^{k}x_i}{(\displaystyle\sum_{i=1}^{m}x_i-\displaystyle\sum_{i=1}^{4}x_i)^2}$$


Kiruvchi ma`lumotlar: Birinchi satrda $n$ ikkinchi satrda massiv elementlari va uchinchi satrda esa $k$ va $m$ berilgan ($1\le k \le m \le n$)


Chiquvchi ma`lumotlar: Masala yechimi $10^{-2}$ aniqlikda aniqlansin

Input
4
44 99 55 12
1 3
Output
1.30
Input
9
35 51 85 14 6 18 62 34 66
4 6
Output
0.47