当前位置: 首页 > news >正文

品牌网站建设渠道网站地图提交地址

品牌网站建设渠道,网站地图提交地址,贵阳网站设计企业,商城微发布GYM101933I - Intergalactic Bidding 题解#xff1a;不考虑首先显然是个背包#xff0c;一开始直接用set模拟#xff0c;然后map存方案#xff0c;这样会mle。发现物品的体积有的特殊性 only one participant was allowed to make a bid at a time, each participant was … GYM101933I - Intergalactic Bidding 题解不考虑首先显然是个背包一开始直接用set模拟然后map存方案这样会mle。发现物品的体积有的特殊性 only one participant was allowed to make a bid at a time, each participant was only allowed to make one bid, and a participant making a bid had to bid at least twice the amount of the highest bid at the time. 于是直接对物品排序贪心取最大即可,因为对于种题目给定的s一定有唯一的方法组成。 #include bits/stdc.h typedef long long ll; const int N 1e3 7; using namespace std; struct Big {char x[1005]; int len;string s;bool operator (const Big A) const {if(A.len ! len) return 0;for(int i 0; i len; i) if(A.x[i] ! x[i]) return 0;return 1;}bool operator (const Big A) const {if(A.len ! len) return len A.len;for(int i len-1; i 0; --i) if(A.x[i] ! x[i]) return x[i] A.x[i];return 0;}Big operator (const Big A) const {Big ans *this;for(int i 0; i A.len; i) {ans.x[i] ans.x[i] A.x[i];}int mx max(A.len, len), f 0;for(int i 0; i mx1; i) {if(ans.x[i] 10) {ans.x[i]-10; ans.x[i1];}if(ans.x[i]) ans.len i1, f 1;}if(!f) ans.len 1;return ans;}Big operator - (const Big A) const {Big ans *this; int f 0;for(int i 0; i A.len; i) {ans.x[i] ans.x[i] - A.x[i];}int mx max(A.len, len);for(int i 0; i mx1; i) {if(ans.x[i] 0) {ans.x[i]10; --ans.x[i1];}if(ans.x[i]) ans.len i1, f 1;}if(!f) ans.len 1;return ans;}void read() {cin s; len s.size();for(int i 0; i len; i) x[len-i-1] s[i]-0;s.clear();}void write() {for(int i len-1; i 0; --i) printf(%d,x[i]); putchar(\n);} } s, ZER;int n; struct node{string nm; Big A;bool operator (const node a) const {return A a.A;} } a[N]; vectorint ans; int main() {ZER.x[0] 0; ZER.len 1;scanf(%d,n);s.read();for(int i 1; i n; i) {cin a[i].nm; a[i].A.read();}sort(a1,a1n);for(int i n ; i 1; --i) {if( a[i].A s || s a[i].A) {ans.push_back(i);s s - a[i].A;}}if(s ZER) {printf(%d\n,(int)ans.size());for(int i 0; i ans.size(); i) {cout a[ans[i]].nm \n;}}else puts(0);return 0; }转载于:https://www.cnblogs.com/RRRR-wys/p/9817446.html
http://www.pierceye.com/news/140070/

相关文章:

  • 网站基本信息设置链接搜索
  • 广州海珠网站开发营销策划
  • 医院网站制作公司专门做spa的网站
  • 企业网页制作与网站设计网站必须天天更新吗
  • 乌苏市城乡建设局网站外贸网网站建设
  • html5网站开发实例书籍凡科建站代理
  • 与建设部网站网站注册登录页面设计
  • 企业网站推广计划免费最新如何建设网站教程视频
  • 17一起做网站普宁站好看个人网页模板
  • 民治营销网站专业网站建设价格最优
  • 免费的html网站做柜子喜欢上哪些网站看
  • 网站没备案怎么做加速现代装修风格三室两厅效果图
  • 互助平台网站建设网上商城怎么购物
  • 百度知道山东网站建设建设网站成本预算
  • 人人做免费网站网站建站是 什么
  • 以背景做网站视频为单位网站建设实施方案
  • 简洁大气企业网站模板西安个人做网站
  • 做一个网站需要到哪里做辽宁同鑫建设网站
  • 开发网站监控推荐扬中市建设局网站
  • 手机网站根目录简述一个网站设计的主要步骤
  • 网站改版seo建议网页设计师的能力
  • 网站上线前应该备案吗温州网站建设风格
  • 网站建设书籍免费聊城市东昌府区建设路小学网站
  • 网站标题优化怎么做找人一起做素材网站
  • 如何创建个人网站模板用织梦做模板网站
  • 平台建站建设做网站一定要有营业执照吗
  • 如何把学校网站建设好天猫店铺购买
  • 网站的建设和推广企业网站建设的主要目的是
  • html5 公众号 网站开发工程公司名称
  • 公司做网站那家好网站二维码怎么制作