#Lutece3200. 卡牌收集

卡牌收集

Migrated from Lutece 3200 卡牌收集

All parts of this problem, including description, images, samples, data and checker, might be broken. If you find bugs in this problem, please contact the admins.

Description

小u同学是个收集爱好者,在前面公园散完步之后,他来到了一家小卖部

这家小卖部有卡牌抽奖活动,规则如下:

一共nn种卡牌,每种卡牌有无数张,第ii种卡牌的权重是wiw_i,每次抽奖之间是相互独立的

每次抽奖抽到第ii种卡牌的概率是wij=1nwj\frac{w_i}{\sum_{j=1}^nw_j}

小u同学想要得到mm种卡牌,他一共有抽kk次的机会

为了权衡利弊,他想知道这种情况的概率是多少,由于小u呆头呆脑的,这个问题又交给了万能的你.

最后请输出得到这种情况的概率对998244353取模的结果

Input

第一行输入三个数nn,mm,kk 接下来输入nn行,每行一个数,第ii行表示wiw_i

Output

输出一个数,即小u抽奖kk次最后得到mm种卡牌的概率(对998244353取模)

Samples

2 1 2
2
1
221832079

Constraints

1mn501\leq m \leq n \leq 50 1k501\leq k \leq 50 0<wi0\lt w_{i} wi<998244353\sum w_i \lt 998244353

Note

样例的概率为59\frac{5}{9} 本题最终的结果需要进行取模,涉及到乘法逆元的知识点,同学们可以提前进行学习 乘法逆元的求解

Resources

2024 UESTC ICPC Training for Search and Dynamic Programming