aboutsummaryrefslogtreecommitdiff
path: root/files/ja/web/javascript/reference/operators/right_shift_assignment
diff options
context:
space:
mode:
Diffstat (limited to 'files/ja/web/javascript/reference/operators/right_shift_assignment')
-rw-r--r--files/ja/web/javascript/reference/operators/right_shift_assignment/index.html61
1 files changed, 61 insertions, 0 deletions
diff --git a/files/ja/web/javascript/reference/operators/right_shift_assignment/index.html b/files/ja/web/javascript/reference/operators/right_shift_assignment/index.html
new file mode 100644
index 0000000000..6ff0bb1cba
--- /dev/null
+++ b/files/ja/web/javascript/reference/operators/right_shift_assignment/index.html
@@ -0,0 +1,61 @@
+---
+title: 右シフト代入 (>>=)
+slug: Web/JavaScript/Reference/Operators/Right_shift_assignment
+tags:
+ - Assignment operator
+ - JavaScript
+ - Language feature
+ - Operator
+ - Reference
+translation_of: Web/JavaScript/Reference/Operators/Right_shift_assignment
+---
+<div>{{jsSidebar("Operators")}}</div>
+
+<p>右シフト代入演算子 (<code>&gt;&gt;=</code>) は、指定された量のビットを右に移動し、結果を変数に代入します。</p>
+
+<div>{{EmbedInteractiveExample("pages/js/expressions-right-shift-assignment.html")}}</div>
+
+<div></div>
+
+
+
+<h2 id="構文">構文</h2>
+
+<pre class="syntaxbox notranslate"><strong>Operator:</strong> x &gt;&gt;= y
+<strong>Meaning:</strong> x = x &gt;&gt; y</pre>
+
+<h2 id="例">例</h2>
+
+<h3 id="右シフト代入の使用">右シフト代入の使用</h3>
+
+<pre class="brush: js notranslate">let a = 5; // (00000000000000000000000000000101)
+a &gt;&gt;= 2; // 1 (00000000000000000000000000000001)
+
+let b = -5; // (-00000000000000000000000000000101)
+b &gt;&gt;= 2; // -2 (-00000000000000000000000000000010)</pre>
+
+<h2 id="仕様">仕様</h2>
+
+<table class="standard-table">
+ <tbody>
+ <tr>
+ <th scope="col">仕様</th>
+ </tr>
+ <tr>
+ <td>{{SpecName('ESDraft', '#sec-assignment-operators', 'Assignment operators')}}</td>
+ </tr>
+ </tbody>
+</table>
+
+<h2 id="ブラウザー実装状況">ブラウザー実装状況</h2>
+
+
+
+<p>{{Compat("javascript.operators.right_shift_assignment")}}</p>
+
+<h2 id="関連項目">関連項目</h2>
+
+<ul>
+ <li><a href="/docs/Web/JavaScript/Guide/Expressions_and_Operators#Assignment">代入演算子</a></li>
+ <li><a href="/docs/Web/JavaScript/Reference/Operators/Right_shift">右シフト演算子</a></li>
+</ul>