算法/数据结构
文章平均质量分 57
zjulbj
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
Project 3: Sort Poems
Project 3: Sort Poems Harry once found an interesting ancient poem written on a long strip of paper. He decided to save this piece of art into his computer by scanning the paper segment by segment.原创 2013-03-29 23:44:08 · 739 阅读 · 0 评论 -
Harry Potter’s Exam (an application of Dijkstra algorithm)
In Professor McGonagall's class of Transfiguration, Harry Potter is learning how to transform one object into another by some spells. He has learnt that, to turn a cat into a mouse one can say docam原创 2013-03-29 23:36:26 · 861 阅读 · 0 评论 -
the algorithms to solve the question X^N
Algorithm 1:time complexity O(N) double pow(double x, long n) { if(n==0) return 1; /*when n=0 whatever the x is,the pow is 1*/ if(n==1) return x; /*when n=1 the result is x itself*/ els原创 2013-03-29 23:31:04 · 598 阅读 · 0 评论
分享