数学
文章平均质量分 76
HITYYJ
这个作者很懒,什么都没留下…
展开
-
hoj 2879 The triangle of Eulerian numbers
Problem come from The 2879 of Hoj . The problem is what is the numbers of permutations of {1,……n} whith k ascends ,increasing or discreasing .Here the question is much easier ,while k is 2.The solut原创 2013-08-17 08:52:32 · 1068 阅读 · 2 评论 -
插值方法实现(拉格朗日插值和牛顿插值)
#include#include#include#include#include#include#include#includeusing namespace std;#define maxn 100double Langrange(double x[],double y[],int n,double xx){ double ans=0; for(int i=0;i<=n原创 2014-02-21 22:40:24 · 2381 阅读 · 0 评论 -
求逆元
#include#include#include#include#include#include#include#include#include#include#include#includeusing namespace std;#define ll long long#define ld long double#define re freopen("in.txt"原创 2014-05-06 15:46:28 · 743 阅读 · 0 评论 -
lightoj 1170 Counting Perfect BST
BST is the acronym for BinarySearch Tree. A BST is a tree data structure with the following properties.i) EachBST contains a root node and the root may have zero, one or two children. Eachof t原创 2014-07-31 10:27:49 · 894 阅读 · 0 评论 -
lightoj 1391 Speed Zones
题目大意:一个人从(0,0)点出发,要到达(100×n,D)这个点。二维平面被分成了平行于x轴的n份,每一份的宽度都是n,每一份的材料不一样导致在每一份当中的速度不一样。求能到达终点的最短时间。思路:拉格朗日乘法+二分。思路来源原创 2014-07-31 11:42:03 · 942 阅读 · 2 评论