码迷,mamicode.com
首页 >  
搜索关键字:round    ( 15566个结果
BestCoder Round #20 部分题解(A,B,C)(hdu5123,5124,5124)
转载请注明出处:http://www.cnblogs.com/fraud/ ——by fraudwho is the best?Time Limit: 2000/1000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Problem...
分类:其他好文   时间:2014-11-30 06:07:30    阅读次数:307
Codeforces Round #220 (Div. 2) D 树状数组 && 二分
/*题目*/ 题意:给了n,m,然后一个包含m个数的数组nnum,数组默认从小到大排序,然后是 n个操作,输入一个数x,若x为0,把0加到这个字符串的末尾,若x为1,把1加到这个字符串的末尾,若x为-1,那么把字符串里的 下标 与 nnum数组里的元素相等的  给删除,字符串一开始是空的,问你最后字符串里有什么,若为空 就输出 POOR STACK 这题目看这操作一般都很容易联想到线段...
分类:编程语言   时间:2014-11-29 20:16:19    阅读次数:221
Codeforces Beta Round #4 (Div. 2 Only) D. Mysterious Present
最长上升子序列,这种水题还是一眼就能看出来的。 题目大意: 主人公想在一张w*h的明信片外套信封。他有n个信封,每个信封的长宽给出,问最多能套多少层。给出从小到大的顺序。 解题思路: 最长上升子序列,只不过是记忆路径。 下面是代码: #include #include #include #include #include #includ...
分类:其他好文   时间:2014-11-29 16:07:20    阅读次数:208
Codeforces Beta Round #5 B. Center Alignment
又是模拟,就当练手吧。 题目大意: 给出一段文本,输出居中显示的样子。当左右空白数量不能平均时,上一个靠左,下一个靠右。 解题思路:见代码~~ 下面是代码: #include #include #include #include #include #include #include #include #include #include ...
分类:其他好文   时间:2014-11-29 16:00:11    阅读次数:185
Codeforces Beta Round #4 (Div. 2 Only) C. Registration system
这个题感觉还不错,以前字典树写的是最顺手的,这几次比赛屡屡挂在字典树上也是有阴影了啊~~ 题目大意: 给出一些字符串,对每个字符串进行查询,若没出现过返回OK,若出现过就生成新字符串,格式为原字符串+数,数为这个字符串第几次重复出现。 解题思路: 字典树,对于每个字符串的插入次数进行计数。 下面是代码: #include #includ...
分类:其他好文   时间:2014-11-29 14:41:37    阅读次数:156
Codeforces Beta Round #4 (Div. 2 Only) B. Before an Exam
继续刷水题,不能再错了!! 题目大意: 要求在n天内学习t小时,给出每一天可以学习的最小时间和最大时间。问能不能实现,若可以输出时间表。 解题思路: 水题一个,保证在区间范围内的情况下直接贪心。 下面是代码: #include #include #include #include #include #include #include ...
分类:其他好文   时间:2014-11-29 13:15:03    阅读次数:156
Codeforces Round #278 (Div. 1)
AA monster is attacking the Cyberland!Master Yang, a braver, is going to beat the monster. Yang and the monster each have 3 attributes: hitpoints (HP)...
分类:其他好文   时间:2014-11-28 22:44:24    阅读次数:247
javascript—Mach的一些常用方法
1、Math.random():返回 0 ~ 1 之间的随机数。2、Math.round():四舍五入取整。3、Math.ceil():向上取整; 例如:a=1.2,b=5.8; 返回的是a=2,b=6;4、Math.floor():向下取整; 例如:a=1.2,b=5.8; 返回的是:a=1,b=...
分类:编程语言   时间:2014-11-28 22:38:55    阅读次数:266
Codeforces Beta Round #4 (Div. 2 Only) A. Watermelon
水题一个,就是记录下已经做过了。 题目大意: 给出一个数,问是否能分成两个偶数。 下面是代码: #include #include #include #include #include #include #include #include #include #include #include #include #define eps 1e-10 #...
分类:其他好文   时间:2014-11-28 14:28:36    阅读次数:166
在不同编程语言中对Unix时间戳进行转换(Unix timestamp)
最近用到unix时间转换在mysql和.net中的应用。将此资料保存在博客中。如何在不同编程语言中获取现在的Unix时间戳(Unix timestamp)?JavatimeJavaScriptMath.round(new Date().getTime()/1000) getTime()返回数值的单....
分类:编程语言   时间:2014-11-28 09:55:53    阅读次数:252
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!