自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

Today is a gift

Mr_Y的问题中心

  • 博客(21)
  • 收藏
  • 关注

POJ 1010 解题报告 STAMPS

考察多判。遍历所有组合,取出最好组合。上代码。 #include <iostream>#include <map>#include <cstring>#include <algorithm>using namespace std;int arrStampType[256];int arrCust...

2011-12-18 21:15:24 105

POJ 1009 解题报告 Edge Detection

1009是痛苦的一题啊。游程编码问题。先说思路:只处理变化的点。产生变化的点会影响周围的8个点的编码。没有产生变化的点的编码值与前一天相同。当然,有几个特殊情况需要注意。先上代码: #include <iostream>#include <algorithm>#include <vector>using namespace...

2011-12-18 21:13:46 214

POJ 1008 解题报告 Maya Calendar

还是要细心啊,题目不难,历法转换。AC吧,这么简单的题烧这么长时间。。。丢人了。。。。 #include <iostream>#include <string>#include <cstdlib>#include <cstdio>using namespace std;int getTotalDays(...

2011-12-16 17:54:59 94

POJ 1007 解题报告 DNA Sorting

 #include <iostream>#include <string>#include <map>using namespace std;class DNA{public: string strDNA; DNA(string);};DNA::DNA(string s){ strDNA = s;}...

2011-12-15 17:43:37 110

原创 POJ 1007 解题报告 DNA Sorting

#include #include #include using namespace std;class DNA{public: string strDNA; DNA(string);};DNA::DNA(string s){ strDNA = s;}int calculateInversionsNum(const string&);bool operator<

2011-12-15 17:39:36 401

POJ 1006 解题报告 Biorhythms

同理小学生计算题?还是我没想到什么?#include &lt;iostream&gt;using namespace std;int getTriple(int, int, int, int);int main (){ int iP; int iE; int iI; int iD; int iCount = 0; while...

2011-12-15 17:39:06 116

POJ 1005 解题报告 I Think I Need a Houseboat

好吧,小朋友的数学题。#include &lt;iostream&gt;#include &lt;math.h&gt;using namespace std;const double PI = atan(1.)*4.;int getYear(double, double);int main (){ int iInput; double dX...

2011-12-15 17:36:35 85

POJ 1004 解题报告 Financial Management

超水一题。#include &lt;iostream&gt;using namespace std;int main (){ int i = 12; double dSum = 0; double d; while (i--) { cin &gt;&gt; d; dSum += d; } cout &lt;&lt; ...

2011-12-15 17:34:23 116

POJ 1003 解题报告 Hangover

简单题。注意不要重复计算。使用二分查找的思想。AC。#include &lt;iostream&gt;#include &lt;map&gt;using namespace std;int getCards(map&lt;int, double&gt;&amp;, double);int binaryChop(map&lt;int, double&...

2011-12-15 17:32:48 115

原创 POJ 1010 解题报告 STAMPS

考察多判。遍历所有组合,取出最好组合。上代码。#include #include #include #include using namespace std;int arrStampType[256];int arrCustomer[256];int arrAnswer[7]; // 0数据长度 1种类 6tie?void showInput();void

2011-12-13 20:29:34 584 1

原创 POJ 1009 解题报告 Edge Detection

1009是痛苦的一题啊。游程编码问题。先说思路:只处理变化的点。产生变化的点会影响周围的8个点的编码。没有产生变化的点的编码值与前一天相同。当然,有几个特殊情况需要注意。先上代码:#include #include #include using namespace std;typedef class Point{public: int iFirst; int i

2011-12-05 15:26:37 5769 1

原创 POJ 1008 解题报告 Maya Calendar

还是要细心啊,题目不难,历法转换。AC吧,这么简单的题烧这么长时间。。。丢人了。。。。#include #include #include #include using namespace std;int getTotalDays(string&, string&, string&);string& turnHolly(int, string&);int main ()

2011-12-01 14:46:49 426

转载 POJ 题目分类

OJ上的一些水题(可用来练手和增加自信)(poj3299,poj2159,poj2739,poj1083,poj2262,poj1503,poj3006,poj2255,poj3094)初期:一.基本算法:     (1)枚举. (poj1753,poj2965)     (2)贪心(poj1328,poj2109,poj2586)     (3)递归和分治法.

2011-11-29 16:38:34 276

原创 POJ 1006 解题报告 Biorhythms

2011-11-27同理小学生计算题?还是我没想到什么?#include using namespace std;int getTriple(int, int, int, int);int main (){ int iP; int iE; int iI; int iD; int iCount = 0; while (cin >> iP >> iE >>

2011-11-27 17:54:40 305

原创 POJ 1005 解题报告 I Think I Need a Houseboat

2011-11-27好吧,小朋友的数学题。#include #include using namespace std;const double PI = atan(1.)*4.;int getYear(double, double);int main (){ int iInput; double dX; double dY; cin >> iI

2011-11-27 17:16:34 353

原创 POJ 1004 解题报告 Financial Management

2011-11-27超水一题。#include using namespace std;int main (){ int i = 12; double dSum = 0; double d; while (i--) { cin >> d; dSum += d; } cout << "{1}quot; << dSum/12 << endl;}

2011-11-27 17:14:36 252

原创 POJ 1003 解题报告 Hangover

2011-11-27简单题。注意不要重复计算。使用二分查找的思想。AC。#include #include using namespace std;int getCards(map&, double);int binaryChop(map&, double, int, int);int main (){ double dLength; map mSt

2011-11-27 16:22:37 289

原创 POJ 1002 解题报告 487-3279

2011-11-25典型的字符串处理问题。刚开始用的vector,果断超时。题目本身没什么难度,只在选择容器上要考虑。AC咯。#include #include #include #include using namespace std;int nicknameToNumber(string&);int main (){ int iPhoneTotal;

2011-11-25 16:07:04 364

POJ 1002 解题报告 487-3279

典型的字符串处理问题。刚开始用的vector,果断超时。题目本身没什么难度,只在选择容器上要考虑。AC咯。 #include &lt;iostream&gt;#include &lt;string&gt;#include &lt;iomanip&gt;#include &lt;map&gt;using namespace std;int nickname...

2011-11-25 15:53:34 101

POJ 1001 解题报告 Exponentiation

高精度浮点数计算。花了我整整一天时间才写好,POJ上给的测试数据都通过,0的1次方和1的0次方之类的输入和加入一些干扰0的输入测试也都通过,但是提交后AC不了,显示Anwser Wrong,不知道什么问题,也没找出来。崩溃了。好好练练吧,鉴于道理已明了,先草草结贴,有时间再看。  #include &lt;iostream&gt;#include &lt;vecto...

2011-11-25 15:15:04 81

原创 POJ 1001 解题报告 Exponentiation

2011-11-23高精度浮点数计算。花了我整整一天时间才写好,POJ上给的测试数据都通过,0的1次方和1的0次方之类的输入和加入一些干扰0的输入测试也都通过,但是提交后AC不了,显示Anwser Wrong,不知道什么问题,也没找出来。崩溃了。好好练练吧,鉴于道理已明了,先草草结贴,有时间再看。#include #include #include using name

2011-11-24 18:34:56 492

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除