Description 补足程序,使得下面程序输出结果是: 1.8 2.4 3.8 4.9 8.8 ~~~~ include include include include include include using namespace std; int main() { // Your Code ...
分类:
其他好文 时间:
2018-05-18 14:19:40
阅读次数:
131
题目链接: http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemCode=3878 ...
分类:
其他好文 时间:
2018-05-17 23:19:48
阅读次数:
192
Description 补足程序使得其输出结果是: 40 ~~~~ include include using namespace std; struct A { int n; A() { }; A(int n_ ):n(n_) { } // Your Code Here }; int main() ...
分类:
其他好文 时间:
2018-05-17 21:13:23
阅读次数:
141
长上升子序列 TimeLimit:1000MS MemoryLimit:64MB 64-bit integer IO format:%lld 已解决 | 点击收藏 | 已有4人收藏了本题 Problem Description 如果一个数列ai 满足 a1 < a2 < ... < aN 则这个数列 ...
分类:
其他好文 时间:
2018-05-17 19:54:51
阅读次数:
149
问题描述: Given a linked list, determine if it has a cycle in it. 我的思路: 用一个指针指向链表头部,另一个指针在链表上移动。若两个指针指向地址相等,则存在环。 然后我没过OJ:) 因为循环链表的尾部并不一定链接头部,可能链接任意节点,此时会 ...
分类:
其他好文 时间:
2018-05-17 11:48:12
阅读次数:
123
题目:http://172.21.85.56/oj/exercise/problem?problem_id=21568 题目大意:老板需要你帮忙浇花。给出N滴水的坐标,y表示水滴的高度,x表示它下落到x轴的位置。 每滴水以每秒1个单位长度的速度下落。你需要把花盆放在x轴上的某个位置,使得从被花盆接着 ...
分类:
其他好文 时间:
2018-05-11 17:17:10
阅读次数:
199
博客园的话插链接链接都是凉的= = 题解 我理解成能不能看到这个圆,除了最后几个圆特殊以外都是等价的,然而我凉了,因为我把圆当成线段来处理,但是,有可能一个圆完全被遮住了,还有一个缝隙,就WA了 计算几何题这点最不好,WA了会想的第一件事就是垃圾OJ卡我精度,反复WA上几次才会知道,自己算法错了 那 ...
分类:
其他好文 时间:
2018-05-10 21:45:35
阅读次数:
164
13195的质数因子有5,7,13和29. 600851475143的最大质数因子是多少? 这里可以肯定的是:1.数字很大,绝对不能暴力。2.如果这是一到OJ题,那么我们的目的就是尽量缩小这个数,减少计算量。 我们都知道,任何一个合数都是可以由他的所有质因素相乘得到的,比如15=3*3*3*3*3, ...
分类:
其他好文 时间:
2018-05-09 22:49:25
阅读次数:
232
题目 Given a binary tree containing digits from 0 9 only, each root to leaf path could represent a number. An example is the root to leaf path 1 2 3 whi ...
分类:
其他好文 时间:
2018-05-08 22:26:37
阅读次数:
180
大学生电影节在北大举办! 这天,在北大各地放了多部电影,给定每部电影的放映时间区间,区间重叠的电影不可能同时看(端点可以重合),问李雷最多可以看多少部电影。 ...
分类:
其他好文 时间:
2018-05-07 14:50:44
阅读次数:
367