#include<iostream>using namespace std;int n,m;int v[101],c[101],p[101],w[101][51];int f[101][51],d[101][51];void shuchu(int a,int b)//递归输出所选择的每个魔法的等级 ...
分类:
其他好文 时间:
2016-03-27 15:55:04
阅读次数:
161
分析:直接求出凸包。再算边长就可以。另外仅仅有一个点时为0.00单独处理,两个点直接为距离也单独处理。 #include<iostream> #include<cmath> #include<algorithm> using namespace std; struct Point { Point() ...
分类:
其他好文 时间:
2016-03-27 15:33:04
阅读次数:
128
一道模板题,一直没发现自己的快速读入读不了负数,我竟然能活到现在真是万幸。 1 #include <iostream> 2 #include <cstdio> 3 #define inf -0x7fffffff 4 #define N 50010 5 using namespace std; 6 s ...
分类:
其他好文 时间:
2016-03-27 15:31:28
阅读次数:
236
1.打包 /*一个二维01背包 样例输入: 6 5 4 10 2 2 20 3 2 40 4 3 30 3 3 样例输出: 50 */ #include<iostream> using namespace std; #include<cstdio> #define N 381 int f[N][N] ...
分类:
其他好文 时间:
2016-03-27 15:21:12
阅读次数:
230
Description Everybody in the Prime Land is using a prime base number system. In this system, each positive integer x is represented as follows: Let {p ...
分类:
其他好文 时间:
2016-03-27 11:08:35
阅读次数:
142
Q: Could we XML or Json for the code development? A: Yes you can BUT only for using it as a proxy of database to store data of entity classes. Use it ...
分类:
其他好文 时间:
2016-03-27 11:01:33
阅读次数:
148
Given an integer, write a function to determine if it is a power of three. Follow up:Could you do it without using any loop / recursion? 最大的int 型3的幂是1 ...
分类:
其他好文 时间:
2016-03-27 07:06:02
阅读次数:
148
第十章
10.10.1#ifndef BAND_H_
#define BAND_H_
#include
using namespace std;
class Band
{
public:
Band(string bandName = "NULL", string account="NULL", double deposit = 0.0);
~Band();...
分类:
编程语言 时间:
2016-03-27 01:57:22
阅读次数:
439
题意: 给n(1 #include #include using namespace std; typedef long long LL; const int mod=1e9+7,N=1e5+5; char a[N]; LL quick_mod(LL a,LL p) //快速幂 (快速幂利用了二分思... ...
分类:
其他好文 时间:
2016-03-26 23:40:34
阅读次数:
305
上课不听课的结果就是讲过的题还要再看一遍,好坑,我觉得这道题思想很好,因为比线段树线段树对于我来说只能算是一个模板,所以发一下留作纪念。 1 #include<cstdio> 2 #include<iostream> 3 #include<cstring> 4 using namespace std ...
分类:
其他好文 时间:
2016-03-26 23:38:48
阅读次数:
237