{"author_name":"kenkoooo","blog_url":"https://kenkoooo.hatenablog.com/","categories":["\u7af6\u6280\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0","AtCoder"],"published":"2017-12-31 23:48:18","width":"100%","provider_name":"Hatena Blog","title":"\u4e26\u5217\u4e8c\u5206\u63a2\u7d22\uff08\u89e3\u8aac\u306a\u3057\u30d0\u30fc\u30b8\u30e7\u30f3\uff09","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fkenkoooo.hatenablog.com%2Fentry%2F2017%2F12%2F31%2F234818\" title=\"\u4e26\u5217\u4e8c\u5206\u63a2\u7d22\uff08\u89e3\u8aac\u306a\u3057\u30d0\u30fc\u30b8\u30e7\u30f3\uff09 - \u5b87\u5b99\u30c4\u30a4\u30c3\u30bf\u30e9\u30fcX\u306e\u6182\u9b31\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","url":"https://kenkoooo.hatenablog.com/entry/2017/12/31/234818","description":"adventar.org\u4e26\u5217\u4e8c\u5206\u63a2\u7d22\u3001\u540d\u524d\u304b\u3089\u3057\u3066\u96e3\u3057\u305d\u3046\u306a\u611f\u3058\u304c\u3057\u3066\u3044\u305f\u304c\u3001\u7279\u306b\u96e3\u3057\u3044\u308f\u3051\u3067\u306f\u306a\u304b\u3063\u305f\u3002 \u4e26\u5217\u4e8c\u5206\u63a2\u7d22 \u500b\u4eba\u7684\u306b\u306f\u4e26\u5217\u3068\u3044\u3046\u540d\u524d\u306f\u6b63\u3057\u304f\u306a\u3044\u6c17\u304c\u3057\u307e\u3059\u3002\u666e\u901a\u306e\u4e8c\u5206\u63a2\u7d22\u306f\u6b21\u306e\u901a\u308a\u3002 let mut ng = 0; let mut ok = m; for _ in 0..30 { let med = (ng + ok) / 2; // \u4f55\u304b\u3057\u3089\u306e\u64cd\u4f5c if (\u4f55\u304b\u3057\u3089\u306e\u6761\u4ef6) { ok = med; } else { ng = med; } } \u4e26\u5217\u4e8c\u5206\u63a2\u7d22\u306f\u6b21\u306e\u901a\u308a\u3002 let mut ng = vec![0; q]; let mut ok = vec![m; q]; for _\u2026","provider_url":"https://hatena.blog","height":"190","blog_title":"\u5b87\u5b99\u30c4\u30a4\u30c3\u30bf\u30e9\u30fcX\u306e\u6182\u9b31","author_url":"https://blog.hatena.ne.jp/kenkoooo/","type":"rich","version":"1.0","image_url":null}