<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>tmtms</author_name>
  <author_url>https://blog.hatena.ne.jp/tmtms/</author_url>
  <blog_title>tmtms のメモ</blog_title>
  <blog_url>https://blog.tmtms.net/</blog_url>
  <categories>
    <anon>Ruby</anon>
  </categories>
  <description>ふと、逆ポーランド記法ってのがあったなーと思い出したんだけど、アルゴリズムを全然忘れてたのでネットで検索して、Rubyで実装してみた。 参考にしたページ→ 数式を逆ポーランド法に変換するための事柄 class ReversePolish # 演算子の優先度 OP = { '+' =&gt; 1, '-' =&gt; 1, '*' =&gt; 2, '/' =&gt; 2, } # @param expr [Array&lt;String&gt;] def initialize(expr) @expr = expr.dup @list = [] end # 逆ポーランド記法に変換 # @return [Array] def par…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fblog.tmtms.net%2Fentry%2F201808%2Freverse-polish&quot; title=&quot;逆ポーランド記法 - tmtms のメモ&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>2018-08-17 01:22:17</published>
  <title>逆ポーランド記法</title>
  <type>rich</type>
  <url>https://blog.tmtms.net/entry/201808/reverse-polish</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
