<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>mayokoex</author_name>
  <author_url>https://blog.hatena.ne.jp/mayokoex/</author_url>
  <blog_title>mayoko’s diary</blog_title>
  <blog_url>https://mayokoex.hatenablog.com/</blog_url>
  <categories>
    <anon>CodeForces</anon>
  </categories>
  <description>問題 codeforces.com 解法 しゃくとり法を使って解きます。まず前準備として, pos[i] = (数 i がある位置), memo[i].first = (数 i より左側にある数で, Foe Pair になってしまううち最も右側にあるもののの位置), memo[i].second = (数 i より右側にある数で, Foe Pair になってしまううち最も左側にあるもののの位置) というのを計算しておきます。で, しゃくとりをするときは, ２つのポインター lp, rp が memo[p[lp]].second lp を満たすように動かしていけば良いです。(lp, rp) に到…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fmayokoex.hatenablog.com%2Fentry%2F2016%2F03%2F30%2F123536&quot; title=&quot;Educational Codeforces Round 10 C. Foe Pairs - mayoko’s diary&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>2016-03-30 12:35:36</published>
  <title>Educational Codeforces Round 10 C. Foe Pairs</title>
  <type>rich</type>
  <url>https://mayokoex.hatenablog.com/entry/2016/03/30/123536</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
