摘要:
StampsGiven a set of N stamp values (e.g., {1 cent, 3 cents}) and an upper limit K to the number of stamps that can fit on an envelope, calculate the largest unbroken list of postages from 1 cent to M cents that can be created.For example, consider stamps whose values are limited to 1 cent and 3 cen 阅读全文
摘要:
Shaping RegionsN opaque rectangles (1 #include
using namespace std;
ifstream cin("rect1.in");
ofstream cout("rect1.out");
const int mm=2600;
class point
{ public: int l,r,u,d; int colour,area; point(){area=0;colour=0;}
}pos[1200];
int ans[mm];
int cas;
int ce;
void kill(int l,int 阅读全文