POJ 2977 Box walking】的更多相关文章

题目链接:http://poj.org/problem?id=2977 Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 2229   Accepted: 598 Description You are given a three-dimensional box of integral dimensions lx × ly × lz The edges of the box are axis-aligned, and one…
POJ2977 小学生的考试题,暴力得出O(1)的解法 #include<iostream> #include<cstdio> #include<cstdlib> #include<cstring> #include<cmath> #include<vector> using namespace std; int ans; void turn(int i,int j,int x,int y,int z,int x0,int y0,in…
Walking Race   Description flymouse's sister wc is very capable at sports and her favorite event is walking race. Chasing after the championship in an important competition, she comes to a training center to attend a training course. The center has N…
Box of Bricks Time Limit: 1000MS   Memory Limit: 10000K Total Submissions: 19949   Accepted: 8029 Description Little Bob likes playing with his box of bricks. He puts the bricks one upon another and builds stacks of different height. "Look, I've buil…
传送门 昨天看到这个题还以为是个脑残的dp, 然而脑残的是我. 题目意思就是从左上角走到右下角, 设x为路径上的最大值-最小值, 求x的最小值. 二分x, 对于每一个x, 枚举下界lower, lower从0开始枚举, 每一次bfs的时候, 如果一个点的值小于lower或者大于lower+x, 那么就不走这个点, 看最后能否走到终点. 自己的整数二分写的真是不忍直视...改了好久. ps:poj2922貌似和这个一样 #include<bits/stdc++.h> using namespac…
各种杂题,水题,模拟,包括简单数论. 1001 A+B 1002 A+B+C 1009 Fat Cat 1010 The Angle 1011 Unix ls 1012 Decoding Task 1019 Grandpa's Other Estate 1034 Simple Arithmetics 1036 Complete the sequence! 1043 Maya Calendar 1054 Game Prediction 1057 Mileage Bank 1067 Rails 10…
1.链接地址: http://poj.org/problem?id=1006 http://bailian.openjudge.cn/practice/2977 2.题目: Biorhythms Time Limit: 1000MS   Memory Limit: 10000K Total Submissions: 107909   Accepted: 33478 Description Some people believe that there are three cycles in a p…
POJ 2152 fire / SCU 2977 fire(树型动态规划) Description Country Z has N cities, which are numbered from 1 to N. Cities are connected by highways, and there is exact one path between two different cities. Recently country Z often caught fire, so the governm…
Walking Race Time Limit: 10000MS   Memory Limit: 131072K Total Submissions: 4123   Accepted: 1029 Case Time Limit: 3000MS Description flymouse’s sister wc is very capable at sports and her favorite event is walking race. Chasing after the championshi…
题目来源:POJ 1442 Black Box 题意:输入xi 输出前xi个数的第i大的数 思路:试了下自己的treap模版 #include <cstdio> #include <cstring> #include <cstdlib> #include <ctime> using namespace std; struct Node { Node *ch[2]; int r; int v; int s; Node(){} Node(int v): v(v)…