<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>goldenCat1990</author_name>
  <author_url>https://blog.hatena.ne.jp/goldenCat1990/</author_url>
  <blog_title>jun01tの日記</blog_title>
  <blog_url>https://blog.jun01t.com/</blog_url>
  <categories>
    <anon>技術</anon>
  </categories>
  <description>🔧 基本的な使い方 a = [1, 2] b = ['a', 'b'] a.product(b) # =&gt; [[1, &quot;a&quot;], [1, &quot;b&quot;], [2, &quot;a&quot;], [2, &quot;b&quot;]] これは、a の各要素と b の各要素をすべての組み合わせでペアにしてくれます。 🧩 配列が1つだけでも使える a = [1, 2, 3] a.product(a) # =&gt; [[1, 1], [1, 2], [1, 3], [2, 1], [2, 2], [2, 3], [3, 1], [3, 2], [3, 3]] これはいわゆるデカルト積（直積）ですね。組み合わせというより順列に近い。 🔄 複数配列を渡…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fblog.jun01t.com%2Fentry%2F2025%2F04%2F12%2F140647&quot; title=&quot;`Array#product` メソッドは組み合わせを作る時に便利 - jun01tの日記&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>2025-04-12 14:06:47</published>
  <title>`Array#product` メソッドは組み合わせを作る時に便利</title>
  <type>rich</type>
  <url>https://blog.jun01t.com/entry/2025/04/12/140647</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
