自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(9)
  • 收藏
  • 关注

原创 UVa 10812 Beat the Spread!

#include #include #include #include #include using namespace std; int main() { int n; int s, d; scanf("%d", &n); while (n-- > 0) { scanf("%d%d", &s, &d); if (s < d || (s + d) & 1) {

2014-05-29 22:44:54 464

原创 UVa 541 Error Correction

#include #include #include #include #include using namespace std; bool bmp[101][101]; int main() { int n; int tmp; int colNum; int rowNum; int col; int row; scanf("%d", &n); while (n != 0

2014-05-29 22:33:36 581

原创 UVa 1585 Score

注意输入最后一行可能没有回车换行,

2014-05-24 00:07:54 722

原创 UVa 539 The Settlers of Catan

调试后第一次就AC,难得!

2014-05-23 23:29:15 411

原创 UVa 10267 Graphical Editor

注意填充颜色判断,避免无限递归。

2014-05-13 23:34:20 344

原创 UVa 10137 The Trip

#include #include #include using namespace std; vector PT; void solve(int n,int average) { int res=0; int res1=0; int res2=0; for(int i=0;i<n;i++) { // data=(PT[i]+0.001

2014-05-13 19:54:00 428

原创 UVa 706 LCD Display

#include #include #include #include #include using namespace std; char LCD[10][5][3]={{{' ','-',' '},{'|',' ','|'},{' ',' ',' '},{'|',' ','|'},{' ','-',' '}},//0 {{' ',

2014-05-13 06:09:33 365

原创 UVa 10189 Minesweeper

#include #include using namespace std; bool field[102][102]; int getNum(int m,int n) { return field[m-1][n-1]+field[m-1][n]+field[m-1][n+1] +field[m][n-1]+field[m][n+1] +fiel

2014-05-12 22:32:49 246

原创 UVa 100 The 3n + 1 problem

#include #include using namespace std; int dp[1000001]; int getMCL(int n) { int newN=0; if(n%2==0) newN=n>>1; else newN=n*3+1; if(n>1000000) return 1+getMCL(newN); else if(dp[n]=

2014-05-12 21:41:35 387

空空如也

空空如也

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

TA关注的人

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