题意:给出N 个数 每次可以取两个数 和不超过k ,价值为两个数的积,至多可以取m次,求价值最大
用mulitset 储存 数,然后从最大的开始取 找到符合的最大的数,然后删去这两个数
最后排序加一下
//#include <bits/stdc++.h>
//using namespace std;
//#define lson l, m, rt<<1
//#define rson m+1, r, rt<<1|1
//#pragma comment(linker, "/STACK:1024000000,1024000000")
//typedef long long LL;
//typedef unsigned long long ULL;
//const int INF = 1<<29;
//const LL mod = 1e9+7;
//const int MAXN = 1100;//点数的最大值
//const int MAXM = 520;//边数的最大值
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <math.h>
#include <string>
#include <iostream>
#include <algorithm>
using namespace std;
#include <queue>
#i