<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>anta1</author_name>
  <author_url>https://blog.hatena.ne.jp/anta1/</author_url>
  <blog_title>antaの競技プログラミング練習日記</blog_title>
  <blog_url>https://anta1.hatenadiary.org/</blog_url>
  <categories>
    <anon>SRM</anon>
    <anon>二分探索</anon>
  </categories>
  <description>問題 Editorial 問題 数列initialが与えられる。 これの各々を移動させて、等差数列の並び替えにしたい。ただしそれぞれの数値は重複があってはいけない。 移動させるのに移動させた分だけコストがかかる。 コストを最小化せよ 2 -2*10^9 解答 Editorialを見た。 まず、数列をソートできる。 そうすると、等差数列の順序はそのままの順序でよくなる。 次に、どれかの数1つはそのままの位置で良い。 そうすると、コストは等差の関数(d =&gt; Σ |v[fixed] + d * (j - fixed) - v[j]|)になる。 そしてこの関数は凸である。何故ならば、Sumの各項は凸…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fanta1.hatenadiary.org%2Fentry%2F20130213%2F1360740878&quot; title=&quot;SRM 281 DIV1 Hard Equidistance - antaの競技プログラミング練習日記&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2013-02-13 16:34:38</published>
  <title>SRM 281 DIV1 Hard Equidistance</title>
  <type>rich</type>
  <url>https://anta1.hatenadiary.org/entry/20130213/1360740878</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
