二分
Wardell Ⅱ
这个作者很懒,什么都没留下…
展开
-
POJ 2549---Sumsets(二分枚举)
传送门:http://poj.org/problem?id=2549 Description Given S, a set of integers, find the largest d such that a + b + c = d where a, b, c, and d are distinct elements of S. Input Several S, each consisting of a line containing an integer 1 <= n <= 1000 ind原创 2020-08-03 23:13:33 · 315 阅读 · 0 评论 -
CodeForces 485D---Maximum Value
https://codeforces.com/problemset/problem/485/D Description You are given a sequence a consisting of n integers. Find the maximum possible value of (integer remainder of a i divided by a j), where 1 ≤ i, j ≤ n and a i ≥ a j. Input The first line contains原创 2020-07-19 18:57:36 · 182 阅读 · 0 评论 -
CodeForces 483B---Friends and Presents(二分)
来源 Description You have two friends. You want to present each of them several positive integers. You want to present cnt 1 numbers to the first friend and cnt 2 numbers to the second friend. Moreover, you want all presented numbers to be distinct, that als原创 2020-07-19 15:50:28 · 294 阅读 · 0 评论