
杂题
文章平均质量分 54
xieshimao
topcoder
展开
-
SWUST OJ 1042: 中缀表达式转换为后缀表达式【表达式转逆波兰表达式】
表达式转逆波兰表达式原创 2023-03-09 15:09:58 · 464 阅读 · 0 评论 -
LeetCode 793. 阶乘函数后 K 个零
LeetCode 793. 阶乘函数后 K 个零原创 2023-02-20 15:50:51 · 437 阅读 · 0 评论 -
leetcode 85. Maximal Rectangle 最大矩形
Given a 2D binary matrix filled with 0's and 1's, find the largest rectangle containing only 1's and return its area.Example:Input:[ ["1","0","1","0","0"], ["1","0","1&quo原创 2018-09-29 12:44:21 · 316 阅读 · 0 评论 -
leetcode 84. Largest Rectangle in Histogram 柱状图中最大的矩形
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 histogram.Above is a histogram where width of each ...原创 2018-09-29 11:06:11 · 389 阅读 · 0 评论 -
leetcode 4.两个排序数组的中位数
给定两个大小为 m 和 n 的有序数组 nums1 和 nums2 。请找出这两个有序数组的中位数。要求算法的时间复杂度为 O(log (m+n)) 。你可以假设 nums1 和 nums2 不同时为空。示例 1:nums1 = [1, 3]nums2 = [2]中位数是 2.0示例 2:nums1 = [1, 2]nums2 = [3, 4]中位数是 (...原创 2018-09-20 14:23:35 · 256 阅读 · 0 评论 -
131. The Skyline Problem 矩形并问题
描述水平面上有 N 座大楼,每座大楼都是矩阵的形状,可以用一个三元组表示 (start, end, height),分别代表其在x轴上的起点,终点和高度。大楼之间从远处看可能会重叠,求出 N 座大楼的外轮廓线。外轮廓线的表示方法为若干三元组,每个三元组包含三个数字 (start, end, height),代表这段轮廓的起始位置,终止位置和高度。请注意合并同样高度的相邻轮廓,不同的...原创 2018-09-06 17:30:53 · 467 阅读 · 0 评论 -
HIT 1014 高精度水题
Niven Numbers Source : Unknown Time limit : 1 sec Memory limit : 32 MSubmitted : 4166, Accepted : 681A Niven number is a number such that the sum of i原创 2011-10-29 20:19:04 · 1359 阅读 · 0 评论 -
HDU 4066 2011ACM福州网络赛
Random SequenceTime Limit: 3000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 98 Accepted Su原创 2011-10-07 21:39:46 · 3018 阅读 · 0 评论 -
HDU 1272 判断树
小希的迷宫 Time Limit : 2000/1000ms (Java/Other) Memory Limit : 65536/32768K (Java/Other)Total Submission(s) : 20 Accepted Submission(s)原创 2011-09-28 16:30:54 · 1056 阅读 · 1 评论 -
HDOJ/HDU 2803 The MAX
The MAXTime Limit: 4000/2000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 957 Accepted Submissio原创 2011-09-21 20:54:42 · 1337 阅读 · 0 评论 -
HDU/HDOJ 1399 Starship Hakodate-maru Asia 2001, Hakodate (Japan)
Starship Hakodate-maru Time Limit : 2000/1000ms (Java/Other) Memory Limit : 65536/32768K (Java/Other)Total Submission(s) : 3 Accepte原创 2011-08-07 08:53:58 · 6768 阅读 · 0 评论 -
HDU/HDOJ 1551 Cable master 2001-2002 ACM Northeastern European Regional Programming Contest
Cable masterTime Limit : 2000/1000ms (Java/Other) Memory Limit : 65536/32768K (Java/Other)Total Submission(s) : 18 Accepted Subm原创 2011-08-07 01:19:37 · 2483 阅读 · 0 评论 -
HDU/HDOJ R(N) 多校联合1
这套题里面最水的一个。。直接根号下暴力就OK了 我的代码:#include#includebool judge(int n){ int t; t=(int)sqrt(n); if(t*t==n) return true; retu原创 2011-08-02 16:29:59 · 909 阅读 · 0 评论 -
HDU/HDOJ 2141 Can you find it?
Problem Description Give you three sequences of numbers A, B, C, then we give you a number X. Now you need to calculate if you can fin原创 2011-08-04 20:23:33 · 2026 阅读 · 0 评论 -
HDU/HDOJ 3903 Trigonometric Function 多校联合7
这个题我没有想到什么特殊的方法我想,三角形的面积s=0.5*a*b*sinC其中a,b都是整数,那么其实S是不是有理数就至关重要如果S是有理数,那么必然sinC也是按照这个思路。利用海伦公式我们可以知道S是多少由于海伦公式有一个根号,那么我们就需要判断根号下面原创 2011-08-03 18:43:27 · 1322 阅读 · 0 评论 -
HDU/HDOJ 3833 YY's new problem
这个题最讨厌了。。数据量虽然号称1w但是居然可以用2重循环暴力。。Orz。。 我的代码:#includeint a[10005];int id[10005];int main(){ int t,n,i,j,tmp; scanf("%原创 2011-08-02 16:28:05 · 1044 阅读 · 0 评论 -
HDOJ/HDU 3877 Special sort
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=3877Problem DescriptionWe all know a+b=c,but now there is a new rule in equations:原创 2011-07-30 11:39:38 · 1335 阅读 · 0 评论