- 博客(260)
- 收藏
- 关注
翻译 斐波那契数列算法及时间复杂度分析
斐波那契数列算法及时间复杂度分析斐波那契数列是一个很有意思的数列,应用领域非常广.定义:F(n+1)=F(n)+F(n-1)有意思的是,F(n)/F(n+1)趋于黄金分割0.618.如何计算斐波那契数呢?最朴素的思想,利用定义.算法1代码如下:12345678staticint
2015-08-04 20:59:18 15936 1
原创 华东交通大学2014年ACM“双基”程序设计竞赛解题报告
华东交通大学2014年ACM“双基”程序设计竞赛解题报告2014-12-01 17:25 68人阅读 评论(0)收藏 举报 ACM1001 KK的GFriend本题水题。遍历输入数据给出的字符串。如果出现的I LOVE U各个字符都至少都有m个的话,则满足要求,否则不满足。之前比赛时,输出描述的字符串和Sample Output不符(Sa
2014-12-03 19:15:38 1794
原创 遗传算法-SGA代码实现
#include#include#include#include#include/* 全局变量 */struct individual /* 个体*/{ unsigned *chrom; /* 染色体 */ double fitness; /* 个
2014-11-01 21:34:37 1681
原创 SQLSever语句新建用户、对用户授权、用户对用户授权等等
基于实验一建立的“图书读者数据库”(Book_Reader_DB)和实验二输入的部分虚拟数据,在SQL Server 2008查询分析器的Transact-SQL语句输入区输入Transact-SQL语句,然后点击“查询”菜单中的“执行”菜单项(或用F5快捷键),执行输入区的Transact-SQL语句。具体实验内容如下:1、视图定义与查询实验① 在“图书读者数据库”(Book_Reade
2014-11-01 21:31:54 7025 3
转载 经典算法研究系列:深入浅出遗传算法
经典算法研究系列:深入浅出遗传算法分类: 01.Algorithms(研究)2011-01-12 20:57 43044人阅读 评论(65) 收藏 举报算法优化生物图像处理数据挖掘经典算法研究系列:七、深入浅出遗传算法 作者:July 二零一一年一月十二日。本文参考:维基百科 华南理工大学电子讲义 互联网--
2014-10-25 17:53:08 1069
原创 Codeforces Round #263 (Div. 2)-C. Appleman and Toastman
C. Appleman and Toastmantime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputAppleman and Toastman play a
2014-09-07 17:02:04 612
原创 Codeforces Round #263 (Div. 2)-B. Appleman and Card Game
B. Appleman and Card Gametime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputAppleman has n cards. Each
2014-09-07 16:59:30 838
原创 Codeforces Round #263 (Div. 2)-C. Appleman and Toastman
A. Appleman and Easy Tasktime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputToastman came up with a very
2014-09-07 16:51:09 669
原创 Codeforces Round #264 (Div. 2)-C. Gargari and Bishops
C. Gargari and Bishopstime limit per test3 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputGargari is jealous that his fr
2014-09-06 15:42:27 774
原创 Codeforces Round #264 (Div. 2)-B. Caisa and Pylons
B. Caisa and Pylonstime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputCaisa solved the problem with the
2014-09-06 15:34:05 656
原创 Codeforces Round #264 (Div. 2)-A. Caisa and Sugar
A. Caisa and Sugartime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputCaisa is going to have a party and
2014-09-06 15:31:09 788
原创 POJ3608-Bridge Across Islands
Bridge Across IslandsTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 8378 Accepted: 2456 Special JudgeDescriptionThousands of thousands years ago th
2014-08-08 12:05:58 1008
原创 POJ2187-Beauty Contest
Beauty ContestTime Limit: 3000MS Memory Limit: 65536KTotal Submissions: 27636 Accepted: 8536DescriptionBessie, Farmer John's prize cow, has just won first place i
2014-08-06 21:22:04 777
原创 POJ2354-Titanic
TitanicTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 2122 Accepted: 535DescriptionIt is a historical fact that during the legendary voyage of "Titanic"
2014-08-05 22:45:48 729
原创 暑期训练赛(6)解题报告
EXOCENTER OF A TRIANGLETime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 3244 Accepted: 1277DescriptionGiven a triangle ABC, the Extriangles of ABC are cons
2014-08-05 19:10:18 767
原创 暑期训练赛(6)E
C. Cutting Figuretime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputYou've gotten an n × m sheet of squared p
2014-08-05 18:34:22 1236
原创 暑期训练赛(6)D
Training little catsTime Limit: 2000MS Memory Limit: 65536KTotal Submissions: 9914 Accepted: 2364DescriptionFacer's pet cat just gave birth to a brood of little
2014-08-05 18:27:25 846
原创 暑期训练赛(6)C
Prison rearrangementTime Limit: 3000MS Memory Limit: 10000KTotal Submissions: 2209 Accepted: 995DescriptionIn order to lower the risk of riots and escape attempts,
2014-08-05 18:21:57 652
原创 暑期训练赛(6)B
C. Messagetime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputDr. Moriarty is about to send a message to Sherl
2014-08-05 18:19:23 1020
原创 暑期训练赛(6)A题
#include#include#include#include#includeusing namespace std;const int maxn = 120005;int du1[maxn],du2[maxn];vectorG[maxn];queueq1,q2;int n,m,k;int solve(){ for(int i=1;i<=
2014-08-05 18:04:39 736
原创 POJ1673-EXOCENTER OF A TRIANGLE
EXOCENTER OF A TRIANGLETime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 3244 Accepted: 1277DescriptionGiven a triangle ABC, the Extriangles of ABC are cons
2014-08-05 17:02:49 931
原创 POJ1106-Transmitters
TransmittersTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 4555 Accepted: 2427DescriptionIn a wireless network with multiple transmitters sending on the
2014-08-05 16:58:52 810
原创 hihoCoder- Trie树
时间限制:10000ms单点时限:1000ms内存限制:256MB描述小Hi和小Ho是一对好朋友,出生在信息化社会的他们对编程产生了莫大的兴趣,他们约定好互相帮助,在编程的学习道路上一同前进。这一天,他们遇到了一本词典,于是小Hi就向小Ho提出了那个经典的问题:“小Ho,你能不能对于每一个我给出的字符串,都在这个词典里面找到以这个字符串开头的所有单词
2014-08-04 20:20:26 948
原创 HDU4907-Task schedule
Task scheduleTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 586 Accepted Submission(s): 292Problem Description有一台机器,并且给你这台机器的工作表
2014-08-04 16:32:33 595
原创 POJ1329-Circle Through Three Points
Circle Through Three PointsTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 3262 Accepted: 1384DescriptionYour team is to write a program that, given the C
2014-08-02 19:46:37 710
原创 任意三角形外界圆的圆心和半径
/**处理:如三点共线,则返回false;否则,返回true,并将计算得到的圆心与半径存放在center和radius众返回。*/bool triangleCircle(const Point& p1,const Point& p2,const Point& p3,Point ¢er,double &radius) { //检查三点是否共线 if( isThreePoi
2014-08-02 19:20:21 1639
原创 Codeforces Div. 2 #259-C. Little Pony and Expected Maximum
C. Little Pony and Expected Maximumtime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputTwilight Sparkle was pla
2014-08-02 14:56:54 664
原创 Codeforces Div. 2 #259-A. Little Pony and Crystal Mine
A. Little Pony and Crystal Minetime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputTwilight Sparkle once got a
2014-08-02 14:55:22 751
原创 Codeforces Div. 2 #259-B. Little Pony and Sort by Shift
B. Little Pony and Sort by Shifttime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputOne day, Twilight Sparkle i
2014-08-02 14:54:48 634
原创 POJ1375-Intervals
IntervalsTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 3970 Accepted: 1149DescriptionIn the ceiling in the basement of a newly open developers building
2014-08-01 16:53:16 768
转载 atan函数与atan2函数的一点区别
atan函数与atan2函数的一点区别2011-09-23 09:16 5462人阅读 评论(3)收藏 举报float atan 和 atan2 都是求反正切函数,如:有两个点 point(x1,y1), 和 point(x2,y2);那么这两个点形成的斜率的角度计算方法分别是:float angle = atan( (y2-y1)/(x2-x1)
2014-08-01 15:29:22 1689 1
原创 POJ1434-Fill the Cisterns!
Fill the Cisterns!Time Limit: 5000MS Memory Limit: 10000KTotal Submissions: 3197 Accepted: 1080DescriptionDuring the next century certain regions on earth will expe
2014-07-31 20:59:03 691
原创 POJ2002-Squares
SquaresTime Limit: 3500MS Memory Limit: 65536KTotal Submissions: 15924 Accepted: 6026DescriptionA square is a 4-sided polygon whose sides have equal length and adja
2014-07-31 18:07:06 632
原创 POJ3565-Ants
AntsTime Limit: 5000MS Memory Limit: 65536KTotal Submissions: 4251 Accepted: 1309 Special JudgeDescriptionYoung naturalist Bill studies ants in school. His an
2014-07-31 15:17:48 656
原创 POJ1177-Picture
PictureTime Limit: 2000MS Memory Limit: 10000KTotal Submissions: 10284 Accepted: 5452DescriptionA number of rectangular posters, photographs and other pictures of t
2014-07-31 14:20:45 556
原创 POJ1389-Area of Simple Polygons
Area of Simple PolygonsTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 3074 Accepted: 1570DescriptionThere are N, 1 <= N <= 1,000 rectangles in the 2-D xy
2014-07-30 16:28:43 650
原创 POJ3695-Rectangles
RectanglesTime Limit: 2000MS Memory Limit: 65536KTotal Submissions: 3497 Accepted: 1003DescriptionYou are developing a software for painting rectangles on the s
2014-07-30 15:41:08 686
原创 POJ1151-Atlantis
AtlantisTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 17048 Accepted: 6493DescriptionThere are several ancient Greek texts that contain descriptions of
2014-07-29 15:04:06 651
原创 POJ2451-Uyuw's Concert
Uyuw's ConcertTime Limit: 6000MS Memory Limit: 65536KTotal Submissions: 6830 Accepted: 2688DescriptionPrince Remmarguts solved the CHESS puzzle successfully. As an
2014-07-28 19:48:52 787
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人