
搜索
文章平均质量分 77
zhouchaoyuan
熟悉c/c++语言,对java有一定的了解,参加过程序设计竞赛,获得过湖南省二等奖,参加过邀请赛,获得过铜奖,对数据结构和算法有一定的认知!对于数据库也是比较熟悉!
展开
-
uva10344
#include#include#include#include#includeint ok,a[10],vis[10];char b[]={'+','-','*'};void dfs(int x,int sum){ int i,j,temp; if(x==4) { if(sum==23) { printf("Possible\n"); ok=0; }原创 2013-08-25 21:38:49 · 872 阅读 · 0 评论 -
hdu1016(素数环)
终于老老实实做了一道题,不容易啊。#include#include#include#include#includeint n,a[25],vis[25];int isprime(int x){ int i; for(i=2;i<x;i++) if(x%i==0) return 0; return 1;}void dfs(int x,int y)//原创 2013-08-10 18:10:12 · 939 阅读 · 0 评论 -
poj2676(数独 sudoku)
SudokuTime Limit: 2000MS Memory Limit: 65536KTotal Submissions: 11943 Accepted: 5952 Special JudgeDescriptionSudoku is a very simple task. A square table with 9原创 2013-08-10 14:56:26 · 1034 阅读 · 0 评论 -
uva297
Quadtrees A quadtree is a representation format used to encode images. The fundamental idea behind the quadtree is that any image can be split into four quadrants. Each quadrant may agai原创 2013-08-02 17:14:58 · 834 阅读 · 0 评论 -
uva10004
Bicoloring In 1976 the ``Four Color Map Theorem" was proven with the assistance of a computer. This theorem states that every map can be colored using only four colors, in such a way that原创 2013-07-25 13:14:38 · 840 阅读 · 0 评论 -
uva839
Not so Mobile Before being an ubiquous communications gadget, a mobile was just a structure made of strings and wires suspending colourfull things. This kind of mobile is usually found h原创 2013-08-03 15:22:29 · 956 阅读 · 0 评论 -
uva10562
Problem DUndraw the Trees Input: Standard InputOutput: Standard Output Time Limit: 2 Seconds Professor Homer has been reported missing. We suspect that his recent research works might have原创 2013-07-31 00:12:44 · 807 阅读 · 0 评论 -
uva10012
How Big Is It? Ian's going to California, and he has to pack his things, including his collection of circles. Given a set of circles, your program must find the smallest rectangular box in原创 2013-09-09 14:05:23 · 790 阅读 · 0 评论 -
uva439
Knight Moves A friend of you is doing research on the Traveling Knight Problem (TKP) where you are to find the shortest closed tour of knight moves that visits each square of a given set原创 2013-07-30 20:09:57 · 1106 阅读 · 0 评论 -
hdu1728
//开始时不死wa就是re,做出来之后疯狂的交了五六次#include #includeint n,m,k,maze[200][200],vis[200][200];int dx[]={-1,1,0,0},dy[]={0,0,-1,1};//UDLRint x1,y1,x2,y2;typedef struct{ int x,y,count;}node;node原创 2013-08-11 10:51:29 · 1029 阅读 · 0 评论 -
uva185
//先判断给定的算式是否正确,这个首先要将罗马数字转化成阿拉伯数字//第二就是看字母用0---9数字代入的时候算式是否成立,1有不可能成立,2只有一个可行解,3有大于等于2的可行解#include #include #include int n,ok,final[50];int encode[]={1,5,10,50,100,500,1000},vis[50];c原创 2013-09-27 21:01:05 · 783 阅读 · 0 评论 -
uva10047
利用四维数组vis[][][][]标志 行 列 颜色 方向 这样就可以了#include #include#include#include#includeint N,M,vis[30][30][6][5];//行 列 颜色 方向int q[30000][4],dx[]={-1,0,1,0},dy[]={0,1,0,-1};//北 东 南 西char原创 2013-08-19 12:37:01 · 877 阅读 · 0 评论 -
hdu1501
ZipperTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 5310 Accepted Submission(s): 1909Problem DescriptionGiven three strings, yo原创 2013-08-11 15:44:42 · 1249 阅读 · 0 评论 -
uva705
图在这里://算连块,没有碰到边缘的符合要求,此题放大三倍,算出来连块的格子数除以3就是结果#include #include#include#include#includeint w,h,ok,sum,max,maze[500][500];void dfs(int x,int y){ if(maze[x][y]) return ; if(x=原创 2013-08-18 21:03:12 · 943 阅读 · 0 评论 -
uva572
Oil Deposits The GeoSurvComp geologic survey company is responsible for detecting underground oil deposits. GeoSurvComp works with one large rectangular region of land at a time, and cre原创 2013-07-27 23:29:55 · 873 阅读 · 0 评论 -
uva165
Stamps The government of Nova Mareterrania requires that various legal documents have stamps attached to them so that the government can derive revenue from them. In terms of recent legi原创 2013-09-15 21:50:28 · 687 阅读 · 0 评论 -
uva301
//有多个订单方案,运输公司可以选择接受订单也可以不接受,但必须保证不要超载(限载量是n),使得运输公司赚钱最多,输出赚最多的钱数。 2.2秒险过#include #include#include#include#includeint n,m,k,maxn;int a[30][5],vis[30],num[30][30];void dfs(int x){ int原创 2013-09-13 22:36:55 · 889 阅读 · 0 评论 -
uva216
#include#include#include#include#include#include#include#include#include#include#includeusing namespace std;double minn,a[20][2],b[20][2],final[20][2],dist[20],finaldi[20];int vis[20];in原创 2013-09-19 19:00:20 · 862 阅读 · 0 评论 -
uva539
#include #include#include#include#includeint n,m,minn;int a[50][50],vis[50][50];void dfs(int x,int sum){ int i; if(sum>minn) minn=sum; for(i=0;i<n;i++) { if(a[x][i]&&!vis[x][i]) {原创 2013-09-19 19:00:58 · 832 阅读 · 0 评论 -
uva639
#include #include#include#include#includeint n,minn;char a[10][10];int judge(int x,int y){ int i,j,k,ok; for(j=0;j<n;j++) { if(a[x][j]=='#') { ok=0; for(k=jy?j:y);k++) { i原创 2013-09-19 19:01:32 · 973 阅读 · 0 评论 -
uva193
#include #include #include #include #include #include using namespace std;int m,n,k,maxn,num=0;int a[110][110],vis[110],b[110],final[110];void dfs(int x,int color){ int i; if(x>n) { if(原创 2013-09-19 18:49:39 · 833 阅读 · 0 评论 -
uva208
#include #include int a[30][30],b[30];int n,m,num,vis[30],can[30];void init(int x){ int i; for(i=2;i<=m;i++) if(a[x][i]&&!can[i]) { can[i]=1; init(i); }}void dfs(int x,int cur){原创 2013-09-19 18:50:23 · 993 阅读 · 0 评论 -
uva10001
http://mathworld.wolfram.com/ElementaryCellularAutomaton.html点击打开链接#include #include #include #include #include #include using namespace std;int k,n,ok;int binary[8],a[35],aa[35],b原创 2013-09-19 18:51:17 · 928 阅读 · 0 评论 -
poj1088
//记忆化搜索#include#includeint a[200][200],vis[200][200],max,r,c;int dx[]={0,0,-1,1},dy[]={-1,1,0,0};int dfs(int x,int y){ int i,nx,ny,temp; if(vis[x][y]) return vis[x][y]; for(i=0;i<4;i++)原创 2013-08-16 22:11:07 · 825 阅读 · 0 评论 -
uva196
还好数据范围不是很大,开始时用了a[1000]][20000][1000]一直RE#include #include#include#include#includeint list[1000][1000],vis[1000][1000];char a[1000][1000][1000];int tonum(char *s)//转换成int类型{ int i,nu原创 2013-08-15 23:09:27 · 1088 阅读 · 0 评论 -
uva784
Maze Exploration A maze of rectangular rooms is represented on a two dimensional grid as illustrated in figure 1a. Each point of the grid is represented by a character. The points of roo原创 2013-07-30 17:35:47 · 786 阅读 · 0 评论 -
uva532
Dungeon Master You are trapped in a 3D dungeon and need to find the quickest way out! The dungeon is composed of unit cubes which may or may not be filled with rock. It takes one minute原创 2013-07-27 22:35:35 · 864 阅读 · 0 评论