- 博客(5)
- 收藏
- 关注
原创 KMP入门必做-匹配
Given two sequences of numbers : a1 1, a2 2, ...... , aN N, and b1 1, b2 2, ...... , bM M (1 K K = b1 1, aK+1 K+1 = b2 2, ...... , aK+M−1 K+M−1 = bM M. If there are more th
2017-02-19 22:02:18 254 1
原创 Strange Fuction
Now, here is a fuction: F(x) = 6 * x^7+8*x^6+7*x^3+5*x^2-y*x (0 Can you find the minimum value when x is between 0 and 100.InputThe first line of the input contains an integer T(1Outpu
2017-02-19 21:13:55 160
原创 合并果子
现在有n堆果子,第i堆有ai个果子。现在要把这些果子合并成一堆,每次合并的代价是两堆果子的总果子数。求合并所有果子的最小代价。Input第一行包含一个整数T(T每组数据第一行包含一个整数n(2第二行包含n个正整数ai(aiOutput每组数据仅一行,表示最小合并代价。Sample Input241 2 3 453 5 2 1 4Sample Ou
2017-02-19 21:05:08 216
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人