2017 icpc 南宁赛区 L.The Heaviest Non-decreasing Subsequence Problem(LIS)
Let SS be a sequence of integers s_{1}s1 , s_{2}s2 , ......, s_{n}sn Each integer is is associated with a weight by the following rules:(1) If is is negative, then its weight is 00.(2) If is is greater than or equal to 1000010000, then