随笔分类 - 母函数
摘要:#include#include#include#include#include#define LL __int64using namespace std;int num[30];int c1[100];int c2[100];void fun(){ int i,j,k,l; memse...
阅读全文
摘要:母函数#include#include#include#include#includeusing namespace std;int dp[50];struct Clas{ int v,c;};Clas cla[50];int c1[500000];int c2[500000];int t,n...
阅读全文
摘要:题意:有1 5 10 25 50 五种硬币 最多取100个 问有多少种方式能凑成 n思路:dp#include#include#include#include#includeusing namespace std;int op[10]={1,5,10,25,50};int dp[300][300...
阅读全文
摘要:题意:有n种物品 每种价值 vi 有 ci件 问分成两堆 最平均的价值分配是多少 思路:01背包#include#include#include#include#includeusing namespace std;int v[100],m[100];int dp[300000];int main(...
阅读全文
摘要:题意:有 1 2^2 3^2...17^2 十七种硬币 问有多少种方式可以凑够 n思路:#include#include#include#includeusing namespace std;int c1[400],c2[400];void fun(int n){ int i,j,k; ...
阅读全文
摘要:Description"Well, it seems the first problem is too easy. I will let you know how foolish you are later." feng5166 says."The second problem is, given ...
阅读全文
摘要:题意: 拉登有面值 1 2 5 的钱币 分别 n1 n2 n5 个 求出最大能连续组合到多大 思路: 想来想去都有bug 最后简单粗暴的一个一个来处理了#include#include#include#include#include#include#include#define mem...
阅读全文

浙公网安备 33010602011771号