码迷,mamicode.com
首页 > 其他好文
hdu1757---A Simple Math Problem(矩阵)
Problem Description Lele now is thinking about a simple function f(x).If x = 10 f(x) = a0 * f(x-1) + a1 * f(x-2) + a2 * f(x-3) + …… + a9 * f(x-10); And ai(0<=i<=9) can only be 0...
分类:其他好文   时间:2015-03-11 21:44:50    阅读次数:145
CSDN-markdown编辑器基本语法与呈现效果对照2
代码块用TAB键起始的段落,会被认为是代码块,如下: echo “hello world"; 呈现效果: echo “hello world"; 如果在一个行内需要引用代码,只要用反引号`引起来就好,如下:Use the `printf()` function.呈现效果: Use the printf() fun...
分类:其他好文   时间:2015-03-11 21:44:44    阅读次数:168
ITFriend创业败局(五):创业可以停止,公司必须注销,不然后果很严重
马上又要继续出来创业做事了,想到要注册公司,有个麻烦事。   事情得回到2014年9月。   当时,由于各种因素,决定放弃ITFriend,当然也放弃了原来了公司。先是,咨询了横德瑞的陈总,关于公司注销的事。他是这么说的:公司注销,需要花费5000元左右,6个月左右的时间。也说道,如果不注销,3年内不能再当法人。     当时,我是这么想的:花这么多钱,还要这么长时间(我比较担心,需要留在北京6个...
分类:其他好文   时间:2015-03-11 21:45:01    阅读次数:138
JDK常用类_lang
String StringBuilder StringBuffer...
分类:其他好文   时间:2015-03-11 21:42:29    阅读次数:110
HDU1690(Floyd)
一开始我以为直线上怎么会有最短距离,后来发现每两点之间直接到和间接到达的距离一样的,比如 1 ->2->3 = 1->2+2->3但是不等于1->3的直接距离 建完图以后直接Floyd就行,还有就是long long 会WA ,用__int64 #include #include #include #include #include #include #include #incl...
分类:其他好文   时间:2015-03-11 21:42:07    阅读次数:153
HDU1535(反向建边)
题意:求从出发点到每个车站的最短距离+从每个车站回到出发点的最短距离是多少 思路:如果从每个点到出发点求一次最短路10^5个点10^5次求SPFA也会超时,那么如果我们反向建边的话可以只用一次SPFA,因为是单向边嘛,把箭头反过来,再求一次起点到各点的最短距离不就行了? #include #include #include using namespace std; const int inf ...
分类:其他好文   时间:2015-03-11 21:42:37    阅读次数:141
hdu 1196 Lowest Bit
#include int main() { int i,n,a[10000],sum,j; while(~scanf("%d",&n)&&n) { sum=1; for(i=0;;i++) { a[i]=n%2; n=n/2; if(a[i]...
分类:其他好文   时间:2015-03-11 21:42:47    阅读次数:129
高并发处理方法总结
高并发处理...
分类:其他好文   时间:2015-03-11 21:43:32    阅读次数:126
HDU2066
#include #include #include #include using namespace std; const int Max_v = 1000 + 10; const int INF = 9999999; int cost[Max_v][Max_v];//权值 int d[Max_v];//顶点s出发最短距离 bool used[Max_v];//以使用过的图 int V...
分类:其他好文   时间:2015-03-11 21:41:42    阅读次数:174
面向对象之继承
关于继承的理解,先看两个类 person类 class Person{ private String name ; private int age ; public void setName(String name){ this.name = name ; } public void setAge(int age){ this.age = age ; } public S...
分类:其他好文   时间:2015-03-11 21:44:00    阅读次数:171
Gray Code 简介及生成
Gray Code 简介及生成...
分类:其他好文   时间:2015-03-11 21:41:27    阅读次数:132
atoi函数编写
#include #include using namespace std; int ai(const char *p){ bool negflag = false; int rs = 0; if(*p=='+'||*p=='-'){ negflag=(*p=='-'); p++; } while(isdigit(*p)){ rs=rs*10+(*p-'0'); p++;...
分类:其他好文   时间:2015-03-11 21:43:30    阅读次数:143
hdu5014(异或+找区间)
题意: 给出一个由0-n这n+1个数字组成的序列; 要求你给出另一个序列有0-n组成,让他们一一对应 异或相加的值最大; 输出最大值,和你给出的序列; 思路: 异或完要得到最大值,就应该要二进制是互补的,如10110^01001; 我们的最大值是n,所以我们首先要找到和n互补的值是多少,例如找到是c和n互补; 那么n-1和c+1互补;n-2和c+2也互补;类推; 然后在用c...
分类:其他好文   时间:2015-03-11 21:40:49    阅读次数:296
Jump Game
Given an array of non-negative integers, you are initially positioned at the first index of the array. Each element in the array represents your maximum jump length at that position. Determine if yo...
分类:其他好文   时间:2015-03-11 21:40:22    阅读次数:126
URAL 1762 Search for a Hiding-Place(数学·模拟)
题意  你在一个n*m个白色正方形格子组成的矩形的某个顶点格子  你沿着45度角的方向走  到了边界就改变方向90度  每次经过一个格子都改变他原来的颜(白或灰)  求你走到另一个顶点格子时矩形中有多少格子是灰色的 这题可以用公式也可以直接模拟  模拟就是一直向右移n-1位 每次超过边界就可以把边界向右移m-1位  用cnt记录超过边界的次数 那么每次都会经过cnt个已经走过的格子 (每个格子最...
分类:其他好文   时间:2015-03-11 21:40:24    阅读次数:135
怀旧风格照片特效
我想说怀旧风格的效果很容易实现,就那么几句话,也没啥可说的。 1 % 怀旧风格滤镜 2 clear all; 3 close all; 4 [FileName,PathName] = uigetfile('*.jpg','Open an Image File'); 5 img = imread([....
分类:其他好文   时间:2015-03-11 21:37:39    阅读次数:340
点乘和叉乘
unity3D里面的点乘和叉乘http://www.cnblogs.com/lifangti/p/unity3D.htmlhttp://blog.csdn.net/oskytonight/article/details/38900087http://www.guokr.com/answer/6576...
分类:其他好文   时间:2015-03-11 21:40:04    阅读次数:119
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!