<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>yambe2002</author_name>
  <author_url>https://blog.hatena.ne.jp/yambe2002/</author_url>
  <blog_title>yambe2002’s diary</blog_title>
  <blog_url>https://yambe2002.hatenablog.com/</blog_url>
  <categories>
  </categories>
  <description>苦戦したのでメモしておく。 n個の風船が１列に並んでいて、それぞれにスコアが設定されている。風船を割ると「左のスコア x この風船のスコア x 右のスコア」だけ得られる。割る順番を工夫して、最終的なトータルスコアを最大化せよ。 ・「左のスコア」「右のスコア」はなかったら1 ・割った風船は詰める 0 1 https://leetcode.com/problems/burst-balloons/ トップダウンでやると計算量がO(N!)となり間に合わない。ボトムアップで考える。 dp[l][r]: nums[l...r]での最大スコア とする。 この範囲で最後にx番目を割るとき、そこで得られるスコア…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fyambe2002.hatenablog.com%2Fentry%2F2020%2F08%2F01%2F054112&quot; title=&quot;LeetCode 312. Burst Balloons - 解法メモ - yambe2002’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>2020-08-01 05:41:12</published>
  <title>LeetCode 312. Burst Balloons - 解法メモ</title>
  <type>rich</type>
  <url>https://yambe2002.hatenablog.com/entry/2020/08/01/054112</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
