上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 16 下一页
摘要: 题目描述 求出1~13的整数中1出现的次数,并算出100~1300的整数中1出现的次数?为此他特别数了一下1~13中包含1的数字有1、10、11、12、13因此共出现6次,但是对于后面问题他就没辙了。ACMer希望你们帮帮他,并把问题更加普遍化,可以很快的求出任意非负整数区间中1出现的次数。 解题思 阅读全文
posted @ 2017-06-07 16:45 qqky 阅读(184) 评论(0) 推荐(0) 编辑
摘要: 题目描述 Given a string containing just the characters'(',')','{','}','['and']', determine if the input string is valid. The brackets must close in the co 阅读全文
posted @ 2017-06-06 21:34 qqky 阅读(179) 评论(0) 推荐(0) 编辑
摘要: 题目描述 Given n non-negative integers representing an elevation map where the width of each bar is 1, compute how much water it is able to trap after rai 阅读全文
posted @ 2017-06-06 21:18 qqky 阅读(178) 评论(0) 推荐(0) 编辑
摘要: 题目描述 Given a string containing just the characters'('and')', find the length of the longest valid (well-formed) parentheses substring. For"(()", the l 阅读全文
posted @ 2017-06-05 10:41 qqky 阅读(223) 评论(0) 推荐(0) 编辑
摘要: [编程题] 分饼干 时间限制:1秒 空间限制:32768K 易老师购买了一盒饼干,盒子中一共有k块饼干,但是数字k有些数位变得模糊了,看不清楚数字具体是多少了。易老师需要你帮忙把这k块饼干平分给n个小朋友,易老师保证这盒饼干能平分给n个小朋友。现在你需要计算出k有多少种可能的数值 输入描述: 输入包 阅读全文
posted @ 2017-06-04 10:51 qqky 阅读(491) 评论(0) 推荐(0) 编辑
摘要: [编程题] 堆砖块 时间限制:1秒 空间限制:32768K 小易有n块砖块,每一块砖块有一个高度。小易希望利用这些砖块堆砌两座相同高度的塔。为了让问题简单,砖块堆砌就是简单的高度相加,某一块砖只能使用在一座塔中一次。小易现在让能够堆砌出来的两座塔的高度尽量高,小易能否完成呢。 输入描述: 输入包括两 阅读全文
posted @ 2017-06-04 10:50 qqky 阅读(1023) 评论(0) 推荐(0) 编辑
摘要: [编程题] 工作安排 时间限制:1秒 空间限制:32768K 现在有n位工程师和6项工作(编号为0至5),现在给出每个人能够胜任的工作序号表(用一个字符串表示,比如:045,表示某位工程师能够胜任0号,4号,5号工作)。现在需要进行工作安排,每位工程师只能被安排到自己能够胜任的工作当中去,两位工程师 阅读全文
posted @ 2017-06-04 10:48 qqky 阅读(289) 评论(0) 推荐(0) 编辑
摘要: 题目描述 Given n non-negative integers representing the histogram's bar height where the width of each bar is 1, find the area of largest rectangle in the 阅读全文
posted @ 2017-06-04 10:47 qqky 阅读(145) 评论(0) 推荐(0) 编辑
摘要: 题目描述 Evaluate the value of an arithmetic expression inReverse Polish Notation. Valid operators are+,-,*,/. Each operand may be an integer or another e 阅读全文
posted @ 2017-06-04 10:45 qqky 阅读(211) 评论(0) 推荐(0) 编辑
摘要: 题目描述 HZ偶尔会拿些专业问题来忽悠那些非计算机专业的同学。今天测试组开完会后,他又发话了:在古老的一维模式识别中,常常需要计算连续子向量的最大和,当向量全为正数的时候,问题很好解决。但是,如果向量中包含负数,是否应该包含某个负数,并期望旁边的正数会弥补它呢?例如:{6,-3,-2,7,-15,1 阅读全文
posted @ 2017-06-02 10:00 qqky 阅读(158) 评论(0) 推荐(0) 编辑
上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 16 下一页