{"categories":[],"author_url":"https://blog.hatena.ne.jp/d_tutuz/","description":"\u554f\u984c https://atcoder.jp/contests/arc097/tasks/arc097_c \u8003\u3048\u65b9 \u72b6\u614b\u3092\u6c7a\u3081\u6253\u3061\u3067\u304d\u308b\u304b\u3069\u3046\u304b\u304c\u4e00\u756a\u91cd\u8981\u306a\u8003\u5bdf\u306a\u6c17\u304c\u3059\u308b\u3002\u3064\u307e\u308a dp[i][j] := \u5de6\u304b\u3089 [1,i] \u307e\u3067\u306e\u9ed2 'B' \u306e\u6570\u3068 [1,j] \u307e\u3067\u306e\u767d 'W' \u306e\u6570\u304c\u6b63\u3057\u304f\u4e26\u3079\u308b\u3088\u3046\u306b\u3059\u308b\u3068\u304d\u306e\u6700\u5c0f\u306eswap\u56de\u6570 \u3068\u5b9a\u7fa9\u3059\u308b\u3068\u3001\u305d\u306e\u6b21\u306b\u7f6e\u304f\u3079\u304d\u6570\u306f\u4e00\u610f\u306b\u6c7a\u307e\u308b\u306e\u3067DP\u3067\u89e3\u3092\u6c42\u3081\u308b\u3053\u3068\u304c\u3067\u304d\u308b\u3002dp[i][j] \u3068\u3057\u305f\u3068\u304d\u306b 'B' \u3092\u6b21\u306b\u7f6e\u304f\u306e\u3067\u3042\u308c\u3070\u305d\u306e\u6570\u306f i+1 \u3067\u3042\u308b\u3057\u3001'W' \u3067\u3042\u308c\u3070 j+1 \u3067\u3042\u308b\u3002 \u3088\u3063\u3066DP\u306e\u5f62\u306f\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u306a\u308b\u3002 dp[i+1][j] = m\u2026","height":"190","provider_name":"Hatena Blog","blog_url":"https://tutuz.hateblo.jp/","blog_title":"\u6570\u5b66/\u7af6\u30d7\u30ed\u30e1\u30e2","title":"AtCoder Regular Contest 097\uff1aE - Sorted and Sorted","image_url":null,"published":"2019-02-11 10:13:27","author_name":"d_tutuz","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Ftutuz.hateblo.jp%2Fentry%2F2019%2F02%2F11%2F101327\" title=\"AtCoder Regular Contest 097\uff1aE - Sorted and Sorted - \u6570\u5b66/\u7af6\u30d7\u30ed\u30e1\u30e2\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","width":"100%","version":"1.0","url":"https://tutuz.hateblo.jp/entry/2019/02/11/101327","provider_url":"https://hatena.blog","type":"rich"}