<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>nkgt_chkonk</author_name>
  <author_url>https://blog.hatena.ne.jp/nkgt_chkonk/</author_url>
  <blog_title>猫型の蓄音機は 1 分間に 45 回にゃあと鳴く</blog_title>
  <blog_url>https://nekogata.hatenablog.com/</blog_url>
  <categories>
    <anon>Scala</anon>
    <anon>programming</anon>
  </categories>
  <description>今回は時間がないので簡単に見ます。 型クラスによってアドホック多相が実現されるとどんな柔軟なことができるのかという例を見ましょう。 たとえば、List#max について見て見ましょう。これ、要素が String だったら辞書順での最大値を返すし、Int だったら数的な意味での最大値を返しますよね。もし「そもそも比べられない型」が要素に入ってたらコンパイルエラーになります。 class Nyan(val value: String) //比べることのできない型 println(List(1, 2, 3).max) // =&gt; 3 println(List(&quot;a&quot;, &quot;b&quot;, &quot;c&quot;).max) …</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fnekogata.hatenablog.com%2Fentry%2F2014%2F07%2F05%2F011544&quot; title=&quot;続・結局型クラスって何がうれしいのっていう話 - 猫型の蓄音機は 1 分間に 45 回にゃあと鳴く&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>2014-07-05 01:15:44</published>
  <title>続・結局型クラスって何がうれしいのっていう話</title>
  <type>rich</type>
  <url>https://nekogata.hatenablog.com/entry/2014/07/05/011544</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
