摘要: Description 一家餐厅有 n 道菜,编号 1...n ,大家对第 i 道菜的评价值为 ai(1≤i≤n)。有 m 位顾客,第 i 位顾客的期 望值为 bi,而他的偏好值为 xi 。因此,第 i 位顾客认为第 j 道菜的美味度为 bi XOR (aj+xi),XOR 表示异或 运算。第 i 阅读全文
posted @ 2016-05-31 20:20 wzj_is_a_juruo 阅读(255) 评论(0) 推荐(0) 编辑
摘要: Description Input Output Sample Input Sample Output HINT 线段树套并查集应该是比较好写的做法,时间复杂度为O(N^3+M*NlogN)。 #include<cstdio> #include<cctype> #include<queue> #in 阅读全文
posted @ 2016-05-31 19:24 wzj_is_a_juruo 阅读(439) 评论(0) 推荐(0) 编辑