<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>xuwei</author_name>
  <author_url>https://blog.hatena.ne.jp/xuwei/</author_url>
  <blog_title>xuwei-k's blog</blog_title>
  <blog_url>https://xuwei-k.hatenablog.com/</blog_url>
  <categories>
    <anon>scala</anon>
  </categories>
  <description>javaでは、以下のように int a = 0; int b = ++a; System.out.print(a); // 1 が表示される System.out.print(b); // bも1 ++というインクリメントするための演算子があります。 しかしscalaの場合 var a = 0 // a ++ これはダメ val b = a += 1 print(a) // 1 が表示される print(b) // b はUnit というようにしないといけません。 この違いについてのおなはし(・ω・)ノ</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fxuwei-k.hatenablog.com%2Fentry%2F20110130%2F1296360331&quot; title=&quot;scalaでは、なぜインクリメントやデクリメントができないのか？ - xuwei-k&amp;#39;s blog&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>2011-01-30 13:05:31</published>
  <title>scalaでは、なぜインクリメントやデクリメントができないのか？</title>
  <type>rich</type>
  <url>https://xuwei-k.hatenablog.com/entry/20110130/1296360331</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
