shui_ti
文章平均质量分 59
Unicoe
这个作者很懒,什么都没留下…
展开
-
算法竞赛入门经典第3章总结
// P47 use getchar input a int#include #include using namespace std;int main(){ int a[10]; int bit = 1; int sum = 0; int i = 0; while((a[i] = getchar()) && a[i] != '\n')原创 2014-07-17 15:51:41 · 608 阅读 · 0 评论 -
uva568-Just the Facts
Just the Facts The expression N!, read as ``N factorial," denotes the product of the first N positive integers, where N is nonnegative. So, for example,NN!01原创 2014-07-17 16:19:10 · 496 阅读 · 0 评论 -
数论uva575-Skew Binary
Skew Binary When a number is expressed in decimal, the k-th digit represents a multiple of 10k. (Digits are numbered from right to left, where the least significant digit is number 0.) F原创 2014-07-17 16:10:25 · 459 阅读 · 0 评论 -
uva350 - Pseudo-Random Numbers
Computers normally cannot generate really random numbers, but frequently are used to generate sequences of pseudo-random numbers. These are generated by some algorithm, but appear for all practical pu原创 2014-07-17 16:22:21 · 648 阅读 · 0 评论 -
HDU2049
#include #include using namespace std;long long arrange(int n, int m) ///此题就是组合问题,复习了一下排列组合公式{ long long outcome = 1; long long outco = 1; for(int i = 1; i <= m; ++i) { o原创 2014-07-08 22:55:44 · 546 阅读 · 0 评论 -
HDU-2050
这题推起来还是能接受的,折线分割平面,应该从直线去推导折线的情况,而且直线分割平面是有现成公式可以用的1条直线将平面分成 2 部分2条直线将平面分成 4 = 2 + 2 部分3条直线将平面分成 7 = 2 + 2 + 3 部分4条直线将平面分成 11 = 2 + 2 + 3 + 4 部分。。。n条直线将圆分成 2+2+3+4+...+n = 1 + n(n+1)/2 (n原创 2014-07-09 00:22:53 · 657 阅读 · 0 评论