import std.algorithm, std.container, std.conv, std.math, std.range, std.typecons, std.stdio, std.string; auto rdsp(){return readln.splitter;} void pick(R,T)(ref R r,ref T t){t=r.front.to!T;r.popFront;} void readV(T...)(ref T t){auto r=rdsp;foreach(ref v;t)pick(r,v);} void readA(T)(size_t n,ref T[]t){t=new T[](n);auto r=rdsp;foreach(ref v;t)pick(r,v);} const mod = 10^^9+7; alias mint = FactorRing!mod; void main() { int n, m, p; readV(n, m, p); int[] v; readA(n, v); v.sort!"a>b"; auto w = new mint[](n); foreach (i; 0..n) w[i] = v[i]; auto wc = w.cumulativeSum; auto pp = new mint[](m+1); pp[0] = 1; foreach (i; 1..m+1) pp[i] = pp[i-1] * p / 100; auto p1p = new mint[](n+1); p1p[0] = 1; foreach (i; 1..n+1) p1p[i] = p1p[i-1] * (100-p) / 100; auto fact = new mint[](n+m); fact[0] = 1; foreach (i; 1..n+m) fact[i] = fact[i-1] * i; auto invFact = new mint[](n+m); invFact[$-1] = fact[$-1].inv; foreach_reverse (i; 1..n+m) invFact[i-1] = invFact[i] * i; auto combi(int n, int r) { return fact[n] * invFact[n-r] * invFact[r]; } auto r = mint(0); foreach (i; 0..m) r += wc[0..n] * combi(n-1+i, i) * p1p[n] * pp[i]; foreach (i; 0..n) r += wc[0..i] * combi(m-1+i, i) * p1p[i] * pp[m]; writeln(r); } class CumulativeSum(T) { size_t n; T[] s; this(T[] a) { n = a.length; s = new T[](n+1); s[0] = T(0); foreach (i; 0..n) s[i+1] = s[i] + a[i]; } T opSlice(size_t l, size_t r) { return s[r]-s[l]; } size_t opDollar() { return n; } } auto cumulativeSum(T)(T[] a) { return new CumulativeSum!T(a); } struct FactorRing(int m, bool pos = false) { version(BigEndian) union { long vl; struct { int vi2; int vi; } } else union { long vl; int vi; } alias FR = FactorRing!(m, pos); @property static init() { return FR(0); } @property int value() { return vi; } @property void value(int v) { vi = mod(v); } alias value this; this(int v) { vi = v; } this(int v, bool runMod) { vi = runMod ? mod(v) : v; } this(long v) { vi = mod(v); } ref auto opAssign(int v) { vi = v; return this; } pure auto mod(int v) const { static if (pos) return v%m; else return (v%m+m)%m; } pure auto mod(long v) const { static if (pos) return cast(int)(v%m); else return cast(int)((v%m+m)%m); } static if (!pos) pure ref auto opUnary(string op: "-")() { return FR(mod(-vi)); } static if (m < int.max / 2) { pure ref auto opBinary(string op)(int r) if (op == "+" || op == "-") { return FR(mod(mixin("vi"~op~"r"))); } ref auto opOpAssign(string op)(int r) if (op == "+" || op == "-") { vi = mod(mixin("vi"~op~"r")); return this; } } else { pure ref auto opBinary(string op)(int r) if (op == "+" || op == "-") { return FR(mod(mixin("vl"~op~"r"))); } ref auto opOpAssign(string op)(int r) if (op == "+" || op == "-") { vi = mod(mixin("vl"~op~"r")); return this; } } pure ref auto opBinary(string op: "*")(int r) { return FR(mod(vl*r)); } ref auto opOpAssign(string op: "*")(int r) { vi = mod(vl*r); return this; } pure ref auto opBinary(string op)(ref FR r) if (op == "+" || op == "-" || op == "*") { return opBinary!op(r.vi); } ref auto opOpAssign(string op)(ref FR r) if (op == "+" || op == "-" || op == "*") { return opOpAssign!op(r.vi); } pure auto opBinary(string op: "/")(FR r) { return FR(mod(vl*r.inv.vi)); } pure auto opBinary(string op: "/")(int r) { return opBinary!op(FR(r)); } ref auto opOpAssign(string op: "/")(ref FR r) { vi = mod(vl*r.inv.vi); return this; } ref auto opOpAssign(string op: "/")(int r) { return opOpAssign!op(FR(r)); } pure auto inv() { int x = vi, a, b; exEuclid(x, m, a, b); return FR(mod(a)); } } pure T exEuclid(T)(T a, T b, ref T x, ref T y) { auto g = a; x = 1; y = 0; if (b) { g = exEuclid(b, a%b, y, x); y -= a/b*x; } return g; }