自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

风、水、云

思、静、随

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

原创 UVA 10071 - Back to High School Physics

1、题目题目来源:UVA 10055 - Hashmat the Brave Warrior2、分析这是一道入门题。题目本身很简单,涉及到一点高中物理的基本知识。/* UVA 10071 - Back to High School Physics 题目大意:一个物体做匀加速直线运动,现在已知在t时刻物体的速度 为v,求物

2015-10-13 17:53:22 382

原创 UVA 10055 - Hashmat the Brave Warrior

题目题目来源:UVA 10055 - Hashmat the Brave Warrior

2015-10-13 16:40:26 408

原创 Windows下安装numpy、sicpy、matplotlib

如题,在windows下为Python安装numpy、sicpy、matplotlib。总结一下,以备查看。numpy: http://www.scipy.org/scipylib/download.htmlscipy: http://www.scipy.org/install.html#individual-packagesmatplotlib: http://matplotlib.

2015-03-12 09:19:37 470

原创 UVA 624 - CD

0-1背包问题。

2014-10-24 19:33:17 385

原创 UVA 348 - Optimal Array Multiplication Sequence

矩阵乘法链的dp问题。

2014-10-22 14:56:20 339

原创 UVA 562 - Dividing coins

0-1背包问题 + 滚动数组。sum =  x + y

2014-10-22 13:56:38 314

原创 UVA 357 - Let Me Count The Ways

相同类型的题做过好的了, 简单dp问题。

2014-10-22 13:10:53 590

原创 UVA 147 - Dollars

简单dp问题。#include #include #include #include #include #include using namespace std;const int size = 30000 + 100;const double eps = 1e-6;int c[] = {5 , 10 , 20 , 50 , 100 , 200 , 500 , 1

2014-10-21 23:19:23 321

原创 UVA 10192 - Vacation

还是dp最长公共子序列。

2014-10-21 22:44:39 284

原创 UVA 10066 - The Twin Towers

这题是dp中的最长公共子列的问题。

2014-10-21 16:44:33 364

原创 UVA 10131 - Is Bigger Smarter?

我采用的是简单的方式,

2014-10-21 16:27:28 443

原创 UVA 116 - Unidirectional TSP

简单的dp问题,很直观,不多说。

2014-10-20 13:08:59 300

原创 UVA 10003 - Cutting Sticks

简单的dp问题,d(i,j)表示第i个切口到第j

2014-10-20 11:20:12 322

原创 UVA 674 - Coin Change

dp问题,d(i,j)表示用前i(从0开始计算)

2014-10-20 10:40:40 338

原创 UVA 10405 - Longest Common Subsequence

经典的dp模型,需要反向递推。

2014-10-19 15:39:14 307

原创 UVA 103 - Stacking Boxes

简单的动态规划,转换为DAG上

2014-10-18 15:09:18 331

原创 POJ 2593 Max Sequence

和POJ 2479 一样,还是最大连续子和

2014-10-18 13:31:32 387

原创 POJ 2479 Maximum sum

这道题和一维最大连续子和很想,题目不难。#include #include #include #include #include #include using namespace std;#define ZHAO_DEBUG 0const int size = 50000 + 10;int f[size];int sum[size];int L_maxsum[siz

2014-10-18 13:01:59 328

原创 UVA 1423 - Guess

一道很好的题,以大小关系来

2014-10-18 09:22:15 320

原创 UVA 10054 - The Necklace

正确的建模很重要,如果选取

2014-10-17 12:33:39 357

原创 UVA 10047 - The Monocycle

状态的正确选取,图的转换,BFS ,一道好题

2014-10-16 18:18:21 268

原创 UVA 10245 - The Closest Pair Problem

采用分割法,利用hash和二分的思想可以

2014-10-15 21:35:15 404

原创 UVA 10557 - XYZZY

这题用的是DFS , 有的麻烦 。要点:结点可以

2014-10-14 22:42:39 282

原创 UVA 532 - Dungeon Master

不难, 图的BFS。#include #include #include #include #include #include #include #include #include using namespace std;const int size = 30 + 10;char s[size][size][size];int v[size][size][siz

2014-10-13 15:03:24 309

原创 UVA 439 - Knight Moves

简单题,图的BFS遍历

2014-10-13 14:10:01 265

原创 UVA 705 - Slash Maze

题目不难,但是有点繁琐,需要仔细分析处理。

2014-10-10 22:27:32 325

原创 UVA 784 - Maze Exploration

图的dfs或是BFS , 不难 , 是代码

2014-10-04 13:13:22 276

原创 c++ 之 namespace

namespace是用以管控命名冲突的一种方法。将各种命名至于不同的namespace中即方便了管理,避免了命名冲突,也使得逻辑上更为清晰。1.1 namespace的定义一个namespcae可以定义在全局作用域中(其实是一个默认的namespace,也可以定义在其它的namespace中,但不能在其它作用域中定义。如:------------main

2014-10-01 14:28:22 532

原创 UVA 307 Sticks

回溯 +剪枝 (对剪枝要求)

2014-09-30 23:13:50 313

原创 UVA 572 - Oil Deposits

图的BFS , 比较简单,注意细节就行。

2014-09-30 11:00:29 249

原创 UVA 10785 - The Mad Numerologist

题目不难,直接上代码。#include #include #include #include #include using namespace std;char x[] = "AUEOI";char y[] = "JSBKTCLDMVNWFXGPYHQZR";int main(){ int n; cin >> n; for(int i = 0 ; i < n ;

2014-09-30 00:30:10 261

原创 UVA 755 - 487--3279

简单题,不多说。

2014-09-29 22:41:33 287

原创 UVA 10562 - Undraw the Trees

很是艰难,写完后看别人的代码都是直接dfs,而没有直接建树,

2014-09-29 22:00:10 341

原创 UVA 839 - Not so Mobile

这题处理两次,看了别人的代码才知道,原来判断

2014-09-29 19:37:20 296

原创 UVA 327 - Evaluating Simple C Expressions

简单题,直接模拟

2014-09-29 18:53:20 399

原创 UVA 699 - The Falling Leaves

简单题,直接模拟就行。#include #include #include #include #include #include using namespace std;const int size = 10000 + 50;int v[size];int r[2*size + 1];void f(int * x , int * y , int now){ if(x

2014-09-29 17:17:15 305

原创 UVA 712 - S-Trees

题目很简单,利用了数组实现完全二叉树。

2014-09-29 16:10:59 257

原创 UVA 297 - Quadtrees

题目大意: 32*32的正方形图片

2014-09-29 15:34:55 377

原创 线性表综述

线性表是一种线性数据结构。线性数据结构的特点是:存在

2014-09-29 09:53:25 373

原创 数据结构综述

解决现实问题时,我们往往

2014-09-29 08:30:50 591

空空如也

空空如也

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

TA关注的人

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