<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>kilrey</author_name>
  <author_url>https://blog.hatena.ne.jp/kilrey/</author_url>
  <blog_title>うっくつさん本を読む。</blog_title>
  <blog_url>https://kilrey.hatenadiary.org/</blog_url>
  <categories>
    <anon>Ruby</anon>
  </categories>
  <description>迷路の生成アルゴリズム。 for 部屋番号 in 0...部屋最大値 部屋を作る break if (作る場所がない) if (部屋番号 != 0) then for 試行数 in 0...トンネル最大値 if (新しい部屋から既存の迷路まで穴を掘る) then break if (!トンネルを複数掘るか) end end end end 大まかにはこのような感じにした。 無駄な計算を省くと速度が上がる。C化するだけでなくアルゴリズムの改良も重要だ。同じ計算を二度しないようにキャッシュするのも大切だ。</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fkilrey.hatenadiary.org%2Fentry%2F20070717%2Fp1&quot; title=&quot;迷路生成 - うっくつさん本を読む。&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>2007-07-17 00:00:00</published>
  <title>迷路生成</title>
  <type>rich</type>
  <url>https://kilrey.hatenadiary.org/entry/20070717/p1</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
