<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>sanjyuku</author_name>
  <author_url>https://blog.hatena.ne.jp/sanjyuku/</author_url>
  <blog_title>のこのこかずのこ</blog_title>
  <blog_url>https://aya-cat-g-tech.hatenadiary.jp/</blog_url>
  <categories>
    <anon>JavaScript</anon>
  </categories>
  <description>長年JavaScriptを使っていても、いまだに、基本的なところで「あれ！？」と思う挙動にぶち当たることがあります。 配列(オブジェクト)同士の比較 let array1 = [&quot;a&quot;, &quot;b&quot;, &quot;c&quot;]; let array2 = [&quot;a&quot;, &quot;b&quot;, &quot;c&quot;]; console.log(array1 == array2); // false 配列(オブジェクト)は、中身が同じでも等価ではない。これは経験からなんとなく予想できます。 オブジェクトはデータの参照元（メモリの位置）で比較しているからのようです。ちょっと不便ではあります。 配列と文字列の比較 let array1 = [&quot;a&quot;,…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Faya-cat-g-tech.hatenadiary.jp%2Fentry%2F2024%2F03%2F11%2F143249&quot; title=&quot;JavaScriptで配列と文字列を比較した時の挙動 - のこのこかずのこ&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>https://thumbnail.image.rakuten.co.jp/@0_mall/book/cabinet/9700/9784873119700_1_3.jpg?_ex=128x128</image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2024-03-11 14:32:49</published>
  <title>JavaScriptで配列と文字列を比較した時の挙動</title>
  <type>rich</type>
  <url>https://aya-cat-g-tech.hatenadiary.jp/entry/2024/03/11/143249</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
