{"id":63,"date":"2022-08-02T11:08:20","date_gmt":"2023-01-04T20:56:22","guid":{"rendered":"https:\/\/www.silicloud.com\/ja\/blog\/index.php\/2023\/11\/30\/java%e3%81%a7%e3%83%ab%e3%83%bc%e3%83%97%e3%82%92%e4%bd%bf%e3%81%86%e6%96%b9%e6%b3%95\/"},"modified":"2025-07-31T13:45:39","modified_gmt":"2025-07-31T04:45:39","slug":"java%e3%81%a7%e3%83%ab%e3%83%bc%e3%83%97%e3%82%92%e4%bd%bf%e3%81%86%e6%96%b9%e6%b3%95","status":"publish","type":"post","link":"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%a7%e3%83%ab%e3%83%bc%e3%83%97%e3%82%92%e4%bd%bf%e3%81%86%e6%96%b9%e6%b3%95\/","title":{"rendered":"Java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5"},"content":{"rendered":"<p>\u8457\u8005\u306f\u5bc4\u4ed8\u30d7\u30ed\u30b0\u30e9\u30e0\u300cWrite for Donations\u300d\u306e\u4e00\u74b0\u3068\u3057\u3066\u3001\u30d5\u30ea\u30fc\u304a\u3088\u3073\u30aa\u30fc\u30d7\u30f3\u30bd\u30fc\u30b9\u57fa\u91d1\u3092\u9078\u3093\u3067\u5bc4\u4ed8\u3059\u308b\u3053\u3068\u306b\u3057\u307e\u3057\u305f\u3002<\/p>\n<h3>\u306f\u3058\u3081\u306b<\/h3>\n<p>\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u3067\u306f\u3001\u53cd\u5fa9\u7684\u306a\u30bf\u30b9\u30af\u3092\u66f8\u304f\u3053\u3068\u306f\u4e00\u822c\u7684\u3067\u3059\u3002\u540c\u3058\u307e\u305f\u306f\u985e\u4f3c\u306e\u30b3\u30fc\u30c9\u3092\u5fc5\u8981\u306a\u56de\u6570\u3060\u3051\u66f8\u3044\u3066\u3001\u30b3\u30fc\u30c9\u306e\u30d6\u30ed\u30c3\u30af\u3092\u7e70\u308a\u8fd4\u3057\u5b9f\u884c\u3059\u308b\u65b9\u6cd5\u304c\u3072\u3068\u3064\u3042\u308a\u307e\u3059\u3002\u3057\u304b\u3057\u3001\u3053\u306e\u30a2\u30d7\u30ed\u30fc\u30c1\u306f\u5b8c\u74a7\u3068\u306f\u8a00\u3048\u305a\u3001\u8aad\u307f\u3065\u3089\u304f\u4fdd\u5b88\u304c\u56f0\u96e3\u306a\u91cd\u8907\u3057\u305f\u30b3\u30fc\u30c9\u304c\u751f\u6210\u3055\u308c\u307e\u3059\u3002\u3088\u308a\u826f\u3044\u9078\u629e\u80a2\u306f\u3001\u30eb\u30fc\u30d7\u3092\u4f7f\u7528\u3059\u308b\u3053\u3068\u3067\u3059\u3002<\/p>\n<p>\u30eb\u30fc\u30d7\u306f\u7e70\u308a\u8fd4\u3057\u30d7\u30ed\u30b0\u30e9\u30e0\u306e\u6d41\u308c\u3092\u5236\u5fa1\u3059\u308b\u305f\u3081\u306e\u69cb\u9020\u3067\u3059\u3002\u5178\u578b\u7684\u306a\u30eb\u30fc\u30d7\u306b\u306f\uff12\u3064\u306e\u90e8\u5206\u304c\u3042\u308a\u307e\u3059\u3002\uff11\u3064\u76ee\u306f\u771f\u507d\u3092\u5224\u5b9a\u3059\u308b\u5236\u5fa1\u6761\u4ef6\u3067\u3059\u3002\uff12\u3064\u76ee\u306f\u6761\u4ef6\u304c\u771f\u3067\u3042\u308b\u304b\u3001\u6761\u4ef6\u304c\u507d\u306b\u306a\u308b\u307e\u3067\u5b9f\u884c\u3055\u308c\u308b\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u3067\u3059\u3002\u771f\u507d\u6761\u4ef6\u306f\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u304c\u5b9f\u884c\u3055\u308c\u308b\u305f\u3073\u306b\u518d\u8a55\u4fa1\u3055\u308c\u307e\u3059\u3002\u30eb\u30fc\u30d7\u306e\u7d42\u4e86\u6761\u4ef6\u306f\u3001\u3053\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u3067\u5b66\u3076\u5404\u7a2e\u306e\u30eb\u30fc\u30d7\u3054\u3068\u306b\u7570\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u30eb\u30fc\u30d7\u306b\u306f\u3001\u4e3b\u306bwhile\u30eb\u30fc\u30d7\u3068for\u30eb\u30fc\u30d7\u306e2\u3064\u306e\u4e3b\u8981\u306a\u7a2e\u985e\u304c\u3042\u308a\u307e\u3059\u3002\u3069\u306e\u7a2e\u985e\u304b\u306f\u3001\u30eb\u30fc\u30d7\u306e\u69cb\u6587\u3068\u30ed\u30b8\u30c3\u30af\u306b\u3088\u3063\u3066\u6c7a\u307e\u308a\u307e\u3059\u3002while\u30eb\u30fc\u30d7\u306f\u30d6\u30fc\u30eb\u6761\u4ef6\u306b\u4f9d\u5b58\u3057\u3066\u3044\u307e\u3059\u3002\u3053\u306e\u6761\u4ef6\u306f\u4e00\u822c\u7684\u306a\u3082\u306e\u3067\u3042\u308a\u3001\u6761\u4ef6\u304c\u771f\u3067\u3042\u308b\u9593\u306f\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u304c\u7e70\u308a\u8fd4\u3057\u5b9f\u884c\u3055\u308c\u307e\u3059\u3002for\u30eb\u30fc\u30d7\u3082\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u3092\u7e70\u308a\u8fd4\u3057\u5b9f\u884c\u3057\u307e\u3059\u304c\u3001\u30eb\u30fc\u30d7\u6761\u4ef6\u306f\u901a\u5e38\u3001\u6574\u6570\u5909\u6570\u306e\u5897\u52a0\u307e\u305f\u306f\u6e1b\u5c11\u306b\u4f9d\u5b58\u3057\u307e\u3059\u3002\u3053\u306e\u5909\u6570\u304c\u7279\u5b9a\u306e\u76ee\u6a19\u5024\u306b\u5230\u9054\u3059\u308b\u3068\u3001\u30eb\u30fc\u30d7\u306f\u7d42\u4e86\u3057\u307e\u3059\u3002<\/p>\n<p>\u3053\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u3067\u306f\u3001while\u30eb\u30fc\u30d7\u3068for\u30eb\u30fc\u30d7\u3092\u4f7f\u7528\u3057\u3066\u7e70\u308a\u8fd4\u3057\u30bf\u30b9\u30af\u3092\u4f5c\u6210\u3057\u3001\u305d\u308c\u305e\u308c\u306e\u5229\u70b9\u3068\u6b20\u70b9\u306b\u3064\u3044\u3066\u5b66\u3073\u307e\u3059\u3002<\/p>\n<h2>\u524d\u63d0\u6761\u4ef6<\/h2>\n<p>\u3053\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u306b\u5f93\u3046\u305f\u3081\u306b\u306f\u3001\u4ee5\u4e0b\u304c\u5fc5\u8981\u3067\u3059\uff1a<\/p>\n<ul class=\"post-ul\">\n<li>An environment in which you can execute Java programs to follow along with the examples. To set this up on your local machine, you will need the following:Java (version 11 or above) installed on your machine, with the compiler provided by the Java Development Kit (JDK). For Ubuntu and Debian, follow the steps for Option 1 in our tutorial How To Install Java with Apt on Ubuntu 22.04. For other operating systems, including Mac and Windows, follow the download options for Java installation.<br \/>\nTo compile and run the code examples, this tutorial uses Java Shell, also known as JShell, which is a Read-Evaluate-Print Loop (REPL) run from the command line. To get started with JShell, check out the Introduction to JShell guide.<\/li>\n<li>Familiarity with Java and object-oriented programming, which you can find in our tutorial How To Write Your First Program in Java.<\/li>\n<li>An understanding of Java data types, which is discussed in our tutorial Understanding Data Types in Java.<\/li>\n<\/ul>\n<h2>\u7e70\u308a\u8fd4\u3057\u51e6\u7406\u3059\u308b\u9593<\/h2>\n<p>while\u30eb\u30fc\u30d7\u306f\u4e00\u822c\u7684\u306a\u30d6\u30fc\u30eb\u578b\u306e\u6761\u4ef6\u6587\u3092\u76e3\u8996\u3057\u307e\u3059\u3002\u4f8b\u3048\u3070\u3001\u6761\u4ef6\u6587\u306f2\u3064\u306e\u6574\u6570\u5909\u6570\u304c\u7b49\u3057\u3044\u304b\u3001\u307e\u305f\u306f2\u3064\u306e\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u304c\u540c\u3058\u304b\u3001\u95a2\u9023\u3057\u3066\u3044\u308b\u304b\u3001null\u3067\u306a\u3044\u304b\u3001\u30d7\u30ed\u30b0\u30e9\u30e0\u3067\u78ba\u8a8d\u3067\u304d\u308b\u4ed6\u306e\u6761\u4ef6\u3092\u691c\u8a3c\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u5b9f\u969b\u306b\u306f\u3001\u4efb\u610f\u306e\u30d6\u30fc\u30eb\u5f0f\u3092\u4f7f\u7528\u3067\u304d\u308b\u305f\u3081\u3001while\u30eb\u30fc\u30d7\u306f\u975e\u5e38\u306b\u5f37\u529b\u3067\u5e83\u304f\u4f7f\u308f\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u3053\u306e\u30bb\u30af\u30b7\u30e7\u30f3\u3067\u306f\u3001while\u30ad\u30fc\u30ef\u30fc\u30c9\u3092\u4f7f\u7528\u3057\u3066Java\u3067\u6700\u521d\u306e\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u30eb\u30fc\u30d7\u3092\u4f5c\u6210\u3057\u307e\u3059\u3002\u30eb\u30fc\u30d7\u3092\u5236\u5fa1\u3059\u308b\u305f\u3081\u306b\u3001\u5358\u4e00\u306eint\u5909\u6570\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002int\u5909\u6570\u306fx\u3068\u547c\u3070\u308c\u3001\u521d\u671f\u5024\u306f3\u3067\u3059\u3002x\u304c0\u3088\u308a\u3082\u5927\u304d\u3044\u9650\u308a\u3001\u30eb\u30fc\u30d7\u306f\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u3092\u7d9a\u3051\u3066\u5b9f\u884c\u3057\u307e\u3059\u3002\u3053\u306e\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u3067\u306f\u3001x\u306e\u5024\u304c\u8868\u793a\u3055\u308c\u3001\u3055\u3089\u306b\u91cd\u8981\u306a\u306e\u306f\u3001\u5404\u5b9f\u884c\u3054\u3068\u306b\u30dd\u30b9\u30c8\u30c7\u30af\u30ea\u30e1\u30f3\u30c8\uff08&#8211;\u6f14\u7b97\u5b50\u3092\u4f7f\u7528\u3057\u3066\uff09\u3055\u308c\u307e\u3059\u3002\u3053\u306e\u30dd\u30b9\u30c8\u30c7\u30af\u30ea\u30e1\u30f3\u30c8\u64cd\u4f5c\u306b\u3088\u308a\u3001\u73fe\u5728\u306e\u30eb\u30fc\u30d7\u306f\u3044\u304f\u3064\u304b\u306e\u5b9f\u884c\u5f8c\u306b\u7d42\u4e86\u3057\u307e\u3059\u3002\u305d\u308c\u304c\u306a\u3051\u308c\u3070\u3001\u30eb\u30fc\u30d7\u306f\u7121\u9650\u306b\u7d9a\u304d\u307e\u3059\u3002<\/p>\n<div class=\"post-conf-info\">\n<p class=\"post-conf-desc\">Info<\/p>\n<div>\u60c5\u5831\uff1a\u3053\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u306e\u4f8b\u306e\u30b3\u30fc\u30c9\u306b\u5f93\u3063\u3066\u9032\u3081\u308b\u305f\u3081\u306b\u306f\u3001\u30ed\u30fc\u30ab\u30eb\u30b7\u30b9\u30c6\u30e0\u3067JShell\u30c4\u30fc\u30eb\u3092\u958b\u3044\u3066\u304f\u3060\u3055\u3044\u3002jshell\u30b3\u30de\u30f3\u30c9\u3092\u5b9f\u884c\u3059\u308b\u3053\u3068\u3067\u958b\u304d\u307e\u3059\u3002\u305d\u308c\u304b\u3089\u3001jshell&gt;\u30d7\u30ed\u30f3\u30d7\u30c8\u306e\u5f8c\u306b\u4f8b\u3092\u8ffd\u52a0\u3057\u3066ENTER\u30ad\u30fc\u3092\u62bc\u3059\u3053\u3068\u3067\u3001\u30b3\u30fc\u30c9\u3092\u30b3\u30d4\u30fc\u3001\u8cbc\u308a\u4ed8\u3051\u3001\u307e\u305f\u306f\u7de8\u96c6\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002JShell\u3092\u7d42\u4e86\u3059\u308b\u306b\u306f\u3001\/exit\u3068\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/div>\n<\/div>\n<p>\u3053\u306e\u30b3\u30fc\u30c9\u3092\u30c6\u30b9\u30c8\u3059\u308b\u305f\u3081\u306b\u3001\u4ee5\u4e0b\u306e\u884c\u3092jshell\u306b\u8cbc\u308a\u4ed8\u3051\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<ol>\n<li data-prefix=\"1\">int x = 3;<\/li>\n<li data-prefix=\"2\"><mark>while<\/mark> (x &gt; 0) {<\/li>\n<li data-prefix=\"3\">System.out.println(&#8220;x is &#8221; + x&#8211;);<\/li>\n<li data-prefix=\"4\">}<\/li>\n<\/ol>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>&nbsp;<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>\u6700\u521d\u306e\u884c\u3067\u3001\u5909\u6570x\u3092\u5b9a\u7fa9\u3057\u307e\u3059\u3002<\/p>\n<p>\u30eb\u30fc\u30d7\u306f2\u884c\u76ee\u3067while\u30ad\u30fc\u30ef\u30fc\u30c9\u3067\u59cb\u307e\u308a\u307e\u3059\u3002\u6761\u4ef6\u6587\uff08x &gt; 0\uff09\u304c\u30eb\u30fc\u30d7\u3092\u5236\u5fa1\u3057\u307e\u3059\u3002\u305d\u308c\u306fx\u304c0\u3088\u308a\u5927\u304d\u3044\u304b\u3069\u3046\u304b\u3092\u6bd4\u8f03\u3057\u307e\u3059\u3002\u305d\u306e\u5f8c\u306b\u958b\u59cb\u62ec\u5f27{\u304c\u7d9a\u304d\u3001\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u306e\u958b\u59cb\u3092\u793a\u3057\u307e\u3059\u3002\u3053\u306e\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u306f\u6761\u4ef6\u304ctrue\uff08x &gt; 0\uff09\u306e\u9593\u3001\u7e70\u308a\u8fd4\u3057\u5b9f\u884c\u3055\u308c\u307e\u3059\u3002<\/p>\n<p>\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u306e\u4e2d\u3067\u30013\u884c\u76ee\u306eSystem.out.println(&#8220;x is &#8221; + x&#8211;);\u3068\u3044\u3046\u6587\u306f\u3001println()\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3057\u3066x\u306e\u73fe\u5728\u306e\u5024\u3092\u51fa\u529b\u3057\u307e\u3059\u3002println()\u30e1\u30bd\u30c3\u30c9\u306e\u5f15\u6570\u306e\u4e2d\u3067\u3001x\u306f\u30b3\u30fc\u30c9x&#8211;\u306b\u3088\u3063\u30661\u3060\u3051\u6e1b\u5c11\u3055\u308c\u307e\u3059\u3002\u5404\u5b9f\u884c\u3054\u3068\u306b\u3001x\u306f1\u305a\u3064\u6e1b\u5c11\u3057\u307e\u3059\u3002(Java\u3067\u6700\u521d\u306e\u30d7\u30ed\u30b0\u30e9\u30e0\u3092\u66f8\u304f\u65b9\u6cd5\u306b\u3064\u3044\u3066\u306f\u3001\u5f53\u793e\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u3092\u3054\u89a7\u304f\u3060\u3055\u3044\u3002)<\/p>\n<p>\u30b3\u30fc\u30c9\u306e\u30d6\u30ed\u30c3\u30af\u306f\u3001\u6700\u5f8c\u306e\u884c\u306b\u3042\u308b\u9589\u3058\u6ce2\u62ec\u5f27 } \u3067\u7d42\u308f\u308a\u307e\u3059\u3002\u3053\u308c\u306f\u540c\u6642\u306b\u30eb\u30fc\u30d7\u306e\u7d42\u308f\u308a\u3067\u3082\u3042\u308a\u307e\u3059\u3002<\/p>\n<p>\u3053\u306e\u30b3\u30fc\u30c9\u3092jshell\u3067\u5b9f\u884c\u3059\u308b\u3068\u3001\u4ee5\u4e0b\u306e\u51fa\u529b\u304c\u8868\u793a\u3055\u308c\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<div class=\"secondary-code-label\" title=\"Output\">Output<\/div>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>x ==&gt; 3 x is 3 x is 2 x is 1<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>\u6700\u521d\u306e\u884c\u306f\u3001x\u304c3\u306e\u5024\u3092\u53d7\u3051\u53d6\u3063\u305f\u3053\u3068\u3092\u78ba\u8a8d\u3057\u3066\u3044\u307e\u3059\u3002\u305d\u306e\u5f8c\u306e\u884c\u3067\u306f\u3001x\u306e\u5024\u304c3\u56de\u51fa\u529b\u3055\u308c\u3001\u6bce\u56de1\u305a\u3064\u6e1b\u5c11\u3057\u307e\u3059\u3002x\u304c3\u30012\u30011\u306e\u5024\u306b\u306a\u308b\u306e\u306f3\u56de\u306e\u53cd\u5fa9\u306e\u307f\u3067\u3059\u3002x\u304c0\u306b\u9054\u3057\u305f\u6642\u70b9\u3067\u6761\u4ef6\u6587x &gt; 0\u304c\u6e80\u305f\u3055\u308c\u306a\u304f\u306a\u308b\u305f\u3081\u3001\u30eb\u30fc\u30d7\u306f\u7d42\u4e86\u3057\u307e\u3059\u3002\u3053\u306e\u6642\u70b9\u3067\u30eb\u30fc\u30d7\u304c\u7d42\u4e86\u3057\u3001\u305d\u308c\u4ee5\u5916\u306b\u306f\u4f55\u3082\u51fa\u529b\u3055\u308c\u307e\u305b\u3093\u3002<\/p>\n<p>\u524d\u306e\u4f8b\u306f\u3001\u30eb\u30fc\u30d7\u3092\u4f5c\u6210\u3059\u308b\u305f\u3081\u306e\u4e00\u822c\u7684\u306a\u65b9\u6cd5\u3067\u3059\u3002\u30eb\u30fc\u30d7\u306e\u610f\u56f3\u306f\u660e\u78ba\u3067\u3042\u308a\u3001\u7d42\u4e86\u6761\u4ef6\u3082\u7c21\u5358\u3067\u3059\uff1a x &gt; 0\u3067\u3059\u3002\u7406\u8ad6\u7684\u306b\u306f\u3001\u8ffd\u52a0\u306e\u5909\u6570\u3084\u6bd4\u8f03\uff08\u305f\u3068\u3048\u3070\u3001x &gt; 0 \u304b\u3064 y &lt; 0\uff09\u3092\u8ffd\u52a0\u3059\u308b\u3053\u3068\u3067\u6761\u4ef6\u3092\u3088\u308a\u8907\u96d1\u306b\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u304c\u3001\u3053\u308c\u306f\u30af\u30ea\u30fc\u30f3\u30b3\u30fc\u30c9\u306e\u89b3\u70b9\u304b\u3089\u306f\u30d9\u30b9\u30c8\u30d7\u30e9\u30af\u30c6\u30a3\u30b9\u3068\u306f\u8003\u3048\u3089\u308c\u307e\u305b\u3093\u3002\u8907\u96d1\u306a\u6761\u4ef6\u306f\u30b3\u30fc\u30c9\u3092\u8ffd\u3044\u306b\u304f\u304f\u3057\u3001\u7406\u89e3\u3057\u306b\u304f\u304f\u3059\u308b\u4e00\u65b9\u3001\u307b\u3068\u3093\u3069\u3001\u3042\u308b\u3044\u306f\u307e\u3063\u305f\u304f\u4fa1\u5024\u3092\u3082\u305f\u3089\u3057\u307e\u305b\u3093\u3002<\/p>\n<h2>do-while\u30eb\u30fc\u30d7<\/h2>\n<p>do-while\u30eb\u30fc\u30d7\u306f\u3001while\u30eb\u30fc\u30d7\u3088\u308a\u3082\u4eba\u6c17\u306f\u3042\u308a\u307e\u305b\u3093\u304c\u3001\u305d\u308c\u3067\u3082\u5e83\u304f\u4f7f\u7528\u3055\u308c\u3066\u3044\u307e\u3059\u3002do-while\u30eb\u30fc\u30d7\u306fwhile\u30eb\u30fc\u30d7\u306b\u4f3c\u3066\u3044\u307e\u3059\u304c\u3001\uff11\u3064\u306e\u91cd\u8981\u306a\u9055\u3044\u304c\u3042\u308a\u307e\u3059\uff1a\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u304c\u5148\u306b\u5b9f\u884c\u3055\u308c\u3001\u305d\u306e\u5f8c\u306b\u30eb\u30fc\u30d7\u6761\u4ef6\u304c\u8a55\u4fa1\u3055\u308c\u307e\u3059\u3002<\/p>\n<p>\u6ce8\u610f\u3068\u3057\u3066\u3001while\u30eb\u30fc\u30d7\u306f\u6700\u521d\u306b\u6761\u4ef6\u3092\u8a55\u4fa1\u3057\u3001\u6761\u4ef6\u304c\u6e80\u305f\u3055\u308c\u306a\u3044\u5834\u5408\u306f\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u3092\u5b9f\u884c\u3057\u307e\u305b\u3093\u3002\u3057\u304b\u3057\u3001do-while\u30eb\u30fc\u30d7\u3067\u306f\u3001\u30eb\u30fc\u30d7\u5236\u5fa1\u6761\u4ef6\u304c\u8a55\u4fa1\u3055\u308c\u308b\u524d\u306b\u5c11\u306a\u304f\u3068\u30821\u56de\u306f\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u304c\u5b9f\u884c\u3055\u308c\u307e\u3059\u3002\u3082\u3057\u6761\u4ef6\u304c\u771f\u306a\u3089\u3070\u3001\u30eb\u30fc\u30d7\u306f\u6761\u4ef6\u304c\u6e80\u305f\u3055\u308c\u306a\u304f\u306a\u308b\u307e\u3067\u8ffd\u52a0\u306e\u7e70\u308a\u8fd4\u3057\u3092\u7d9a\u3051\u307e\u3059\u3002\u305d\u306e\u305f\u3081\u3001do-while\u30eb\u30fc\u30d7\u306f\u8cea\u554f\u3092\u3057\u3066\u6b63\u3057\u3044\u7b54\u3048\u304c\u5f97\u3089\u308c\u308b\u307e\u3067\u306e\u307f\u30eb\u30fc\u30d7\u3092\u7d42\u4e86\u3055\u305b\u308b\u3088\u3046\u306a\u5834\u5408\u306b\u4fbf\u5229\u3067\u3059\u3002<\/p>\n<p>\u3053\u306e\u30bb\u30af\u30b7\u30e7\u30f3\u3067\u306f\u3001\u524d\u306e\u30bb\u30af\u30b7\u30e7\u30f3\u3067\u306ewhile\u30eb\u30fc\u30d7\u306b\u4f3c\u305fdo-while\u30eb\u30fc\u30d7\u3092\u4f5c\u6210\u3057\u307e\u3059\u3002int\u5909\u6570\u306fx\u3068\u547c\u3070\u308c\u3001\u521d\u671f\u5024\u306f3\u3067\u3059\u3002\u3057\u304b\u3057\u3001\u4eca\u56de\u306f\u6761\u4ef6\u304c\u9006\u8ee2\u3057\u3066\u3044\u307e\u3059\uff08x &lt; 0\uff09\u3001\u305d\u3057\u3066\u6761\u4ef6\u304c\u8a55\u4fa1\u3055\u308c\u308b\u524d\u306b\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u304c\u5b9f\u884c\u3055\u308c\u307e\u3059\u3002<\/p>\n<p>JShell\u3092\u958b\u304d\u3001do-while\u30eb\u30fc\u30d7\u3092\u8ffd\u52a0\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<ol>\n<li data-prefix=\"1\">int x = 3;<\/li>\n<li data-prefix=\"2\"><mark>do<\/mark> {<\/li>\n<li data-prefix=\"3\">System.out.println(&#8220;x is &#8221; + x&#8211;);<\/li>\n<li data-prefix=\"4\">} <mark>while<\/mark> (x &lt; 0);<\/li>\n<\/ol>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>&nbsp;<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>\u3053\u306e\u30b3\u30fc\u30c9\u306f\u3001\u524d\u306e\u30bb\u30af\u30b7\u30e7\u30f3\u306ewhile\u30eb\u30fc\u30d7\u3068\u3044\u304f\u3064\u304b\u306e\u985e\u4f3c\u70b9\u304c\u3042\u308a\u307e\u3059\u3002\u307e\u305a\u3001\u5909\u6570x\u306e\u5272\u308a\u5f53\u3066\u304c\u3042\u308a\u307e\u3059\u304c\u3001\u518d\u30733\u3067\u3059\u3002<\/p>\n<p>2\u884c\u76ee\u3067\u306f\u3001\u30ad\u30fc\u30ef\u30fc\u30c9\u300cdo\u300d\u3068\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u306e\u305f\u3081\u306e\u958b\u59cb\u30d6\u30e9\u30b1\u30c3\u30c8\u300c{\u300d\u3092\u4f7f\u3063\u3066\u30eb\u30fc\u30d7\u304c\u958b\u59cb\u3055\u308c\u307e\u3059\u30023\u884c\u76ee\u3067\u306f\u3001println()\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u3063\u3066x\u306e\u5024\u304c\u8868\u793a\u3055\u308c\u307e\u3059\u3002println()\u30e1\u30bd\u30c3\u30c9\u3067\u306f\u3001\u3055\u3089\u306bpostdecrement\u6f14\u7b97\u5b50&#8211;\u3092\u4f7f\u3063\u3066x\u306e\u5024\u3092\u30c7\u30af\u30ea\u30e1\u30f3\u30c8\u3057\u307e\u3059\u3002<\/p>\n<p>\u6700\u5f8c\u306e\u884c\u306b\u306f\u3001\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u306e\u9589\u3058\u62ec\u5f27}\u304c\u3042\u308a\u3001\u7d9a\u3044\u3066\u6761\u4ef6\u6587(x &lt; 0)\u3092\u6301\u3064while\u30ad\u30fc\u30ef\u30fc\u30c9\u304c\u7d9a\u304d\u307e\u3059\u3002\u3053\u308c\u304c\u524d\u306ewhile\u30eb\u30fc\u30d7\u3068\u7570\u306a\u308b\u90e8\u5206\u3067\u3059\u3002\u3053\u3053\u3067\u306f\u6761\u4ef6\u304c\u53cd\u8ee2\u3057\u3066\u3044\u307e\u3059\uff1ax\u306f0\u3088\u308a\u5c0f\u3055\u304f\u306a\u3051\u308c\u3070\u306a\u308a\u307e\u305b\u3093\u3002\u524d\u306e\u4f8b\u3067\u306f\u3001\u6761\u4ef6\u5f0f\u306fx\u304c0\u3088\u308a\u5927\u304d\u3044\u5fc5\u8981\u304c\u3042\u308a\u307e\u3057\u305f\u3002\u3053\u306e\u5909\u66f4\u306b\u3088\u308a\u3001\u6761\u4ef6\u304c\u6e80\u305f\u3055\u308c\u306a\u304f\u3066\u3082\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u306f\u4e00\u5ea6\u3060\u3051\u5b9f\u884c\u3055\u308c\u308b\u3053\u3068\u304c\u793a\u3055\u308c\u307e\u3059\u3002<\/p>\n<p>jshell\u3067\u3053\u306e\u30b3\u30fc\u30c9\u3092\u5b9f\u884c\u3059\u308b\u3068\u3001\u4ee5\u4e0b\u306e\u51fa\u529b\u304c\u8868\u793a\u3055\u308c\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<div class=\"secondary-code-label\" title=\"Output\">Output<\/div>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>x ==&gt; 3 x is 3<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>\u6700\u521d\u306e\u884c\u3067\u306f\u3001x\u306e\u5024\u304c3\u3067\u3042\u308b\u3053\u3068\u3092\u78ba\u8a8d\u3057\u3066\u3044\u307e\u3059\u30022\u884c\u76ee\u3067\u306f\u3001x\u304c3\u3067\u3042\u308b\u3068\u8868\u793a\u3055\u308c\u3066\u3044\u307e\u3059\u3002\u3053\u306edo-while\u30eb\u30fc\u30d7\u306e\u7279\u7570\u6027\u306f\u3001\u6761\u4ef6\uff08x &lt; 0\uff09\u304c\u6e80\u305f\u3055\u308c\u306a\u304f\u3066\u3082\u3001\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u304c\u5c11\u306a\u304f\u3068\u3082\u4e00\u5ea6\u306f\u5b9f\u884c\u3055\u308c\u308b\u70b9\u3067\u3059\u3002\u3053\u306e\u7121\u6761\u4ef6\u306e\u5b9f\u884c\u306f\u5fc5\u305a\u3057\u3082\u5e38\u306b\u671b\u307e\u3057\u3044\u308f\u3051\u3067\u306f\u306a\u3044\u305f\u3081\u3001do-while\u30eb\u30fc\u30d7\u3092\u4f7f\u7528\u3059\u308b\u969b\u306b\u306f\u6ce8\u610f\u304c\u5fc5\u8981\u3067\u3059\u3002\u3053\u306e\u6ce8\u610f\u70b9\u306e\u305f\u3081\u3001do-while\u30eb\u30fc\u30d7\u306f\u3042\u307e\u308a\u983b\u7e41\u306b\u4f7f\u7528\u3055\u308c\u307e\u305b\u3093\u3002<\/p>\n<h2>\u30eb\u30fc\u30d7\u306b\u3064\u3044\u3066<\/h2>\n<p>\u4ee3\u66ff\u306e\u30eb\u30fc\u30d7\u69cb\u9020\u3068\u3057\u3066\u3001for\u30eb\u30fc\u30d7\u304c\u3042\u308a\u307e\u3059\u3002\u3053\u308c\u306fwhile\u30eb\u30fc\u30d7\u3068\u540c\u3058\u304f\u6761\u4ef6\u306e\u4e0b\u3067\u30b3\u30fc\u30c9\u306e\u30d6\u30ed\u30c3\u30af\u3092\u7e70\u308a\u8fd4\u3057\u5b9f\u884c\u3059\u308b\u305f\u3081\u306b\u4f7f\u7528\u3055\u308c\u307e\u3059\u304c\u3001\u3088\u308a\u591a\u304f\u306e\u30aa\u30d7\u30b7\u30e7\u30f3\u304c\u3042\u308a\u307e\u3059\u3002\u30eb\u30fc\u30d7\u5236\u5fa1\u6761\u4ef6\u3067\u306f\u3001\u4e00\u6642\u5909\u6570\u3092\u8ffd\u52a0\u3057\u3001\u5236\u5fa1\u6761\u4ef6\u3092\u5b9a\u7fa9\u3057\u3001\u4e00\u6642\u5909\u6570\u306e\u5024\u3092\u5909\u66f4\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u3053\u308c\u306b\u3088\u308a\u3001\u30eb\u30fc\u30d7\u3092\u5236\u5fa1\u3059\u308b\u3059\u3079\u3066\u306e\u8981\u7d20\u3092\u7d50\u3073\u3064\u3051\u3001\u4f55\u304b\u3092\u898b\u843d\u3068\u3057\u305f\u308a\u30df\u30b9\u3092\u3059\u308b\u53ef\u80fd\u6027\u3092\u6e1b\u3089\u3059\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u3053\u308c\u306b\u3088\u308a\u3001\u30b3\u30fc\u30c9\u3092\u304d\u308c\u3044\u3067\u7406\u89e3\u3057\u3084\u3059\u304f\u4fdd\u3064\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u3088\u308a\u53b3\u683c\u306a\u30b9\u30bf\u30a4\u30eb\u306b\u5f93\u3063\u3066\u30b3\u30fc\u30c9\u3092\u66f8\u304d\u305f\u3044\u5834\u5408\u306b\u306f\u3001for\u30eb\u30fc\u30d7\u306e\u65b9\u304c\u9069\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u4ee5\u4e0b\u306f\u5178\u578b\u7684\u306afor\u30eb\u30fc\u30d7\u3067\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<ol>\n<li data-prefix=\"jshell&gt;\"><mark><span class=\"token keyword\">for<\/span><\/mark> <span class=\"token punctuation\">(<\/span>int x <span class=\"token operator\">=<\/span> <span class=\"token number\">3<\/span><span class=\"token punctuation\">;<\/span> x <span class=\"token operator\">&gt;<\/span> <span class=\"token number\">0<\/span><span class=\"token punctuation\">;<\/span> x&#8211;<span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<\/span><\/li>\n<li data-prefix=\"jshell&gt;\">System.out.println<span class=\"token punctuation\">(<\/span><span class=\"token string\">&#8220;x is &#8220;<\/span> + x<span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><\/li>\n<li data-prefix=\"jshell&gt;\"><span class=\"token punctuation\">}<\/span><\/li>\n<\/ol>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>&nbsp;<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>\u6700\u521d\u306e\u884c\u306b\u306ffor\u30ad\u30fc\u30ef\u30fc\u30c9\u3067\u30eb\u30fc\u30d7\u304c\u59cb\u307e\u308a\u307e\u3059\u3002\u62ec\u5f27\u5185\u306e\u6761\u4ef6\u6587\u306b\u306f3\u3064\u306e\u90e8\u5206\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n<ul class=\"post-ul\">\n<li>int x = 3 defines a variable (x). Defining a temporary variable here is convenient because they are only needed for the loop, so it makes sense to integrate them into the loop. In contrast, when you used a while loop, you had to declare the variable separately before the loop.<\/li>\n<li>x &gt; 0 is the condition that has to be met for the block of code to be executed. In this case, x has to be bigger than 0. This part is similar to the while loop control statement, which only contains the condition to be evaluated.<\/li>\n<li>x&#8211; is the action taken during each successful iteration. In this case, a postdecrement operation decreases the value of x after each successful execution.<\/li>\n<\/ul>\n<p>2\u884c\u76ee\u306eSystem.out.println(&#8220;x is &#8221; + x); \u306e\u6587\u306f\u3001println() \u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3057\u3066x\u306e\u5024\u3092\u51fa\u529b\u3057\u307e\u3059\u3002 x\u306e\u5024\u306f\u5909\u66f4\u3055\u308c\u305a\u306b\u305d\u306e\u307e\u307e\u51fa\u529b\u3055\u308c\u307e\u3059\u3002\u4e00\u65b9\u3001while\u30eb\u30fc\u30d7\u5185\u3067x\u306e\u5024\u3092\u64cd\u4f5c\u3059\u308b\u305f\u3081\u306bprintln() \u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3057\u307e\u3057\u305f\u3002\u3057\u304b\u3057\u3001\u3053\u308c\u306f\u5fc5\u8981\u3042\u308a\u307e\u305b\u3093\u3002\u306a\u305c\u306a\u3089\u3001\u6761\u4ef6\u6587\u306e3\u3064\u76ee\u306e\u90e8\u5206\u3067\u65e2\u306bpostdecrement\u64cd\u4f5c\u304c\u884c\u308f\u308c\u3066\u3044\u308b\u305f\u3081\u3067\u3059\uff1ax&#8211;\u3002<\/p>\n<p>3\u884c\u76ee\u306f\u3001\u30b3\u30fc\u30c9\u306e\u30d6\u30ed\u30c3\u30af\u3068\u5168\u4f53\u306e\u30eb\u30fc\u30d7\u69cb\u9020\u3092\u3001\u9589\u3058\u62ec\u5f27}\u3067\u7d42\u4e86\u3055\u305b\u307e\u3059\u3002<\/p>\n<p>\u3053\u306e\u30b3\u30fc\u30c9\u3092jshell\u3067\u5b9f\u884c\u3059\u308b\u3068\u3001\u6b21\u306e\u51fa\u529b\u304c\u8868\u793a\u3055\u308c\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<div class=\"secondary-code-label\" title=\"Output\">Output<\/div>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>x is 3 x is 2 x is 1<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>\u51fa\u529b\u306f\u3001\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u304c3\u56de\u5b9f\u884c\u3055\u308c\u305f\u3053\u3068\u3092\u78ba\u8a8d\u3057\u307e\u3059\u3002\u6700\u521d\u306e\u5b9f\u884c\u3067\u306f\u3001x\u306e\u5024\u306f3\u3067\u3059\u30022\u56de\u76ee\u306e\u5b9f\u884c\u3067\u306f\u3001x\u306f2\u3067\u3042\u308a\u30013\u56de\u76ee\u306e\u5b9f\u884c\u3067\u306fx\u306f1\u3067\u3059\u30023\u56de\u76ee\u306e\u5b9f\u884c\u5f8c\u3001x\u306f0\u306b\u306a\u308a\u3001\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\uff08x\u306e\u5024\u3092\u8868\u793a\u3059\u308b\uff09\u306f\u5b9f\u884c\u3055\u308c\u305a\u306b\u30eb\u30fc\u30d7\u304c\u7d42\u4e86\u3057\u307e\u3059\u3002<\/p>\n<p>\u3053\u306efor\u30eb\u30fc\u30d7\u306f\u3001while\u30eb\u30fc\u30d7\u3068\u540c\u3058\u7d50\u679c\u3092\u5f97\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u30d1\u30d5\u30a9\u30fc\u30de\u30f3\u30b9\u3068\u30ea\u30bd\u30fc\u30b9\u306e\u4f7f\u7528\u306b\u95a2\u3057\u3066\u306f\u3001\u9055\u3044\u306f\u307b\u3068\u3093\u3069\u3042\u308a\u307e\u305b\u3093\u306e\u3067\u3001\u3069\u3061\u3089\u306e\u30eb\u30fc\u30d7\u3092\u4f7f\u7528\u3059\u308b\u304b\u306f\u500b\u4eba\u306e\u597d\u307f\u306e\u554f\u984c\u3067\u3059\u3002\u305f\u3060\u3057\u3001\u53cd\u5fa9\u56de\u6570\u304c\u308f\u304b\u3063\u3066\u3044\u308b\u5834\u5408\u306f\u3001\u901a\u5e38\u306ffor\u30eb\u30fc\u30d7\u3092\u597d\u3093\u3067\u4f7f\u7528\u3057\u307e\u3059\u3002\u306a\u305c\u306a\u3089\u3001\u30b3\u30fc\u30c9\u3092\u3088\u308a\u8a73\u7d30\u306b\u8ffd\u3046\u3053\u3068\u304c\u3067\u304d\u308b\u304b\u3089\u3067\u3059\u3002<\/p>\n<h2>foreach\u30eb\u30fc\u30d7<\/h2>\n<p>foreach\u30eb\u30fc\u30d7\u306f\u4ed6\u306e\u30eb\u30fc\u30d7\u3068\u4f3c\u3066\u3044\u307e\u3059\u304c\u3001\u5c11\u306a\u3044\u30b3\u30fc\u30c9\u3067\u5024\u306e\u30b0\u30eb\u30fc\u30d7\u3092\u7e70\u308a\u8fd4\u3057\u51e6\u7406\u3059\u308b\u305f\u3081\u306b\u7279\u5225\u306b\u8a2d\u8a08\u3055\u308c\u3066\u3044\u307e\u3059\u3002\u5024\u306e\u30b0\u30eb\u30fc\u30d7\u304c\u3042\u308b\u9650\u308a\u3001\u305d\u308c\u3089\u306e\u6570\u3084\u7e70\u308a\u8fd4\u3057\u306e\u9032\u884c\u3092\u8ffd\u8de1\u3059\u308b\u5fc5\u8981\u306a\u304f\u3001\u305d\u308c\u3089\u3092\u9010\u4e00\u53d6\u308a\u51fa\u3057\u3066\u8868\u793a\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002foreach\u30eb\u30fc\u30d7\u306f\u3001\u30b0\u30eb\u30fc\u30d7\u306b\u5024\u304c\u3042\u308b\u5834\u5408\u306b\u305d\u308c\u3089\u3092\u4e00\u3064\u305a\u3064\u53d6\u308a\u51fa\u3057\u3066\u63d0\u4f9b\u3057\u3066\u304f\u308c\u307e\u3059\u3002<\/p>\n<p>\u307b\u3068\u3093\u3069\u306e\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u8a00\u8a9e\u306b\u306f\u3001foreach\u30eb\u30fc\u30d7\u306e\u4fbf\u5229\u306a\u30b7\u30e7\u30fc\u30c8\u30ab\u30c3\u30c8\u304c\u3042\u308a\u307e\u3059\u3002Java\u3067\u306f\u3001\u72ec\u81ea\u306eforeach\u30ad\u30fc\u30ef\u30fc\u30c9\u306f\u3042\u308a\u307e\u305b\u3093\u304c\u3001\u4ee3\u308f\u308a\u306bfor\u30ad\u30fc\u30ef\u30fc\u30c9\u304c\u4f7f\u7528\u3055\u308c\u307e\u3059\u3002\u305f\u3060\u3057\u3001foreach\u306e\u6761\u4ef6\u6587\u306f\u901a\u5e38\u306efor\u30eb\u30fc\u30d7\u3068\u7570\u306a\u308a\u307e\u3059\u3002\u6b21\u306b\u3054\u78ba\u8a8d\u3044\u305f\u3060\u3051\u307e\u3059\u3002<\/p>\n<p>foreach\u30eb\u30fc\u30d7\u3067\u4f5c\u696d\u3059\u308b\u305f\u3081\u306b\u306f\u3001\u5024\u306e\u30b0\u30eb\u30fc\u30d7\u3092\u4f7f\u7528\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u305d\u3057\u3066\u3001\u305d\u306e\u76ee\u7684\u306b\u306f\u914d\u5217\u304c\u9069\u3057\u3066\u3044\u307e\u3059\u3002\u914d\u5217\u306f\u3001\u540c\u3058\u578b\u306e\u5024\u3092\u542b\u3080\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3067\u3059\u3002\u4ee5\u4e0b\u306e\u4f8b\u3067\u306f\u3001int\u5024\u3092\u542b\u3080\u914d\u5217\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002<\/p>\n<p>\u4ee5\u4e0b\u306e\u30b3\u30fc\u30c9\u3092jshell\u306b\u8ffd\u52a0\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<ol>\n<li data-prefix=\"1\">int[] numbers = {0, 1, 2};<\/li>\n<li data-prefix=\"2\"><mark>for<\/mark> (int x<mark>:<\/mark> numbers) {<\/li>\n<li data-prefix=\"3\">System.out.println(x);<\/li>\n<li data-prefix=\"4\">}<\/li>\n<\/ol>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>&nbsp;<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>\u6700\u521d\u306e\u884c\u3067\u30010\u30011\u30012\u306e3\u3064\u306e\u6574\u6570\u3092\u542b\u3093\u3060int\u914d\u5217\u3092\u4f5c\u6210\u3057\u307e\u3059\u3002<\/p>\n<p>2\u884c\u76ee\u3067foreach\u30eb\u30fc\u30d7\u304cfor\u30ad\u30fc\u30ef\u30fc\u30c9\u3067\u59cb\u307e\u308a\u307e\u3059\u3002\u6b21\u306b\u3001\u4e00\u6642\u5909\u6570int x\u3092\u5b9a\u7fa9\u3057\u307e\u3059\u304c\u3001\u305d\u306e\u5f8c\u308d\u306b\u30b3\u30ed\u30f3\u304c\u7d9a\u304d\u307e\u3059\u3002\u30b3\u30ed\u30f3\u306fforeach\u64cd\u4f5c\u306e\u30b7\u30e7\u30fc\u30c8\u30ab\u30c3\u30c8\u3068\u3057\u3066\u4f7f\u7528\u3055\u308c\u307e\u3059\u3002\uff08foreach\u30eb\u30fc\u30d7\u6587\u306f\u3001Java\u3067\u552f\u4e00\u30b3\u30ed\u30f3\u304c\u4f7f\u7528\u3055\u308c\u308b\u5834\u6240\u3067\u3059\u3002\uff09\u30b3\u30ed\u30f3\u306e\u5f8c\u308d\u306b\u306f\u3001\u914d\u5217\u306a\u3069\u306e\u5024\u306e\u30b3\u30ec\u30af\u30b7\u30e7\u30f3\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n<p>foreach\u30eb\u30fc\u30d7\u6587\u306e\u5f8c\u306b\u306f\u3001numbers\u914d\u5217\u306e\u5404\u5024\u306b\u5bfe\u3057\u3066\u5b9f\u884c\u3055\u308c\u308b\u30b3\u30fc\u30c9\u30d6\u30ed\u30c3\u30af\u304c\u3042\u308a\u307e\u3059\u3002\u3053\u306e\u5834\u5408\u3001System.out.println(x)\u306e\u6587\u306f\u3001println()\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3057\u3066x\u306e\u5024\u3092\u51fa\u529b\u3057\u3001\u305d\u308c\u306fnumbers\u914d\u5217\u306e\u5404\u5024\u3092\u53c2\u7167\u3057\u307e\u3059\u3002<\/p>\n<p>\u4e0a\u8a18\u306e\u30b3\u30fc\u30c9\u3092jshell\u3067\u5b9f\u884c\u3059\u308b\u3068\u3001\u4ee5\u4e0b\u306e\u51fa\u529b\u304c\u8868\u793a\u3055\u308c\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<div class=\"secondary-code-label\" title=\"Output\">Output<\/div>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>numbers ==&gt; int[3] { 0, 1, 2 } 0 1 2<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>\u6700\u521d\u306e\u884c\u3067\u306f\u30010\u30011\u30012\u3068\u3044\u3046\u5024\u3092\u542b\u3080numbers\u3068\u3044\u3046\u914d\u5217\u304c\u5b9a\u7fa9\u3055\u308c\u3066\u3044\u308b\u3053\u3068\u304c\u78ba\u8a8d\u3055\u308c\u307e\u3059\u3002\u4ee5\u4e0b\u306b\u306f\u3001\u914d\u5217\u306e\u5024\u304c\u305d\u308c\u305e\u308c\u65b0\u3057\u3044\u884c\u306b\u51fa\u529b\u3055\u308c\u307e\u3059\uff1a0\u30011\u30012\u3002<\/p>\n<p>\u4ed6\u306e\u30eb\u30fc\u30d7\u3092\u4f7f\u7528\u3059\u308b\u3053\u3068\u306f\u3001\u4e3b\u306b\u500b\u4eba\u306e\u9078\u629e\u306e\u554f\u984c\u3067\u3059\u304c\u3001foreach\u30eb\u30fc\u30d7\u306f\u5024\u306e\u30b0\u30eb\u30fc\u30d7\u3092\u53cd\u5fa9\u51e6\u7406\u3059\u308b\u305f\u3081\u306e\u4e8b\u5b9f\u4e0a\u306e\u6a19\u6e96\u3067\u3059\u3002for\u30eb\u30fc\u30d7\u3084while\u30eb\u30fc\u30d7\u3092\u4f7f\u7528\u3057\u3066foreach\u30eb\u30fc\u30d7\u306e\u4ee3\u66ff\u3092\u4f5c\u6210\u3059\u308b\u3053\u3068\u3082\u53ef\u80fd\u3067\u3059\u304c\u3001\u305d\u308c\u306b\u306f\u5927\u304d\u306a\u52aa\u529b\u3068\u30c7\u30fc\u30bf\u69cb\u9020\u306e\u6df1\u3044\u7406\u89e3\u304c\u5fc5\u8981\u3067\u3042\u308a\u3001\u305d\u308c\u307b\u3069\u4fa1\u5024\u304c\u3042\u308a\u307e\u305b\u3093\u3002<\/p>\n<h2>\u7121\u9650\u30eb\u30fc\u30d7<\/h2>\n<p>\u7121\u9650\u30eb\u30fc\u30d7\u306f\u3001\u5236\u5fa1\u6761\u4ef6\u304c\u5e38\u306b\u771f\u306e\u5834\u5408\u306b\u7d42\u4e86\u3057\u306a\u3044for\u30eb\u30fc\u30d7\u307e\u305f\u306fwhile\u30eb\u30fc\u30d7\u3067\u3059\u3002<\/p>\n<p>\u4ee5\u4e0b\u306f\u3001\u7121\u9650\u306ewhile\u30eb\u30fc\u30d7\u306e\u4e00\u822c\u7684\u306a\u4f8b\u3067\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<ol>\n<li data-prefix=\"jshell&gt;\"><span class=\"token keyword\">while<\/span> <span class=\"token punctuation\">(<\/span>true<span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<\/span><\/li>\n<li data-prefix=\"jshell&gt;\">System.out.println<span class=\"token punctuation\">(<\/span><span class=\"token string\">&#8220;This will print forever.&#8221;<\/span><span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><\/li>\n<li data-prefix=\"jshell&gt;\"><span class=\"token punctuation\">}<\/span><\/li>\n<\/ol>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>&nbsp;<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>\u6700\u521d\u306e\u884c\u306f\u5178\u578b\u7684\u306awhile\u30eb\u30fc\u30d7\u306e\u3088\u3046\u306b\u898b\u3048\u307e\u3059\u304c\u3001x &gt; 0\u306e\u3088\u3046\u306a\u6761\u4ef6\u3067\u306f\u306a\u304f\u3001\u5358\u306btrue\u3068\u3044\u3046\u5024\u304c\u3042\u308a\u307e\u3059\u3002\u3053\u306e\u5834\u5408\u3001\u5236\u5fa1\u6761\u4ef6\u3092\u8a55\u4fa1\u3059\u308b\u5fc5\u8981\u304c\u3042\u308b\u3068\u304d\u306b\u306f\u5e38\u306btrue\u304c\u76f4\u63a5\u8fd4\u3055\u308c\u307e\u3059\u3002\u3053\u306e\u5834\u5408\u3001\u30eb\u30fc\u30d7\u3092\u7d42\u4e86\u3059\u308b\u65b9\u6cd5\u304c\u306a\u3044\u305f\u3081\u3001\u6c38\u9060\u306b\u7d9a\u304d\u307e\u3059\u3002\u4e8c\u884c\u76ee\u306b\u306fSystem.out.println(&#8220;This will print forever.&#8221;);\u3068\u3044\u3046\u6587\u304c\u542b\u307e\u308c\u3066\u304a\u308a\u3001println()\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3057\u3066\u30c6\u30ad\u30b9\u30c8\u300cThis will print forever.\u300d\u3092\u8868\u793a\u3057\u307e\u3059\u3002<\/p>\n<p>\u4e0a\u8a18\u306e\u30b3\u30fc\u30c9\u3092jshell\u3067\u5b9f\u884c\u3059\u308b\u3068\u3001\u6b21\u306e\u51fa\u529b\u304c\u8868\u793a\u3055\u308c\u307e\u3059\u3002\u30b3\u30fc\u30c9\u3092\u7d42\u4e86\u3059\u308b\u307e\u3067\u306b\u7d20\u65e9\u304f\u30ad\u30fc\u30dc\u30fc\u30c9\u306eCTRL+C\u306e\u7d44\u307f\u5408\u308f\u305b\u3067\u7d42\u4e86\u3059\u308b\u6e96\u5099\u3092\u3057\u3066\u304f\u3060\u3055\u3044\u3002\u305d\u3046\u3057\u306a\u3044\u3068\u3001\u7121\u9650\u306b\u7d9a\u304d\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<div class=\"secondary-code-label\" title=\"Output\">Output<\/div>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>This will print forever. This will print forever. &#8230;<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>\u6700\u521d\u306e2\u3064\u306e\u7e70\u308a\u8fd4\u3057\u3057\u304b\u8868\u793a\u3055\u308c\u307e\u305b\u3093\u304c\u3001\u3053\u306e\u51fa\u529b\u306fCTRL+C\u3092\u62bc\u3057\u3066\u624b\u52d5\u3067\u7d42\u4e86\u3059\u308b\u307e\u3067\u7d9a\u304d\u307e\u3059\u3002<\/p>\n<p>\u7121\u9650\u30eb\u30fc\u30d7\u306e\u4f8b\u3067\u306f\u3001\u30d6\u30fc\u30eb\u5024\u306e\u4ee3\u308f\u308a\u306b\u5358\u4e00\u306e\u771f\u306e\u5024\u304c\u914d\u7f6e\u3055\u308c\u308b\u3053\u3068\u3067\u3001\u305d\u306e\u3088\u3046\u306a\u30eb\u30fc\u30d7\u3092\u4f5c\u6210\u3059\u308b\u660e\u78ba\u306a\u610f\u56f3\u304c\u3042\u308a\u307e\u3059\u3002\u904e\u53bb\u306b\u306f\u3053\u306e\u3088\u3046\u306a\u30eb\u30fc\u30d7\u304c\u4eba\u6c17\u304c\u3042\u308a\u3001\u30ec\u30ac\u30b7\u30fc\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u3082\u898b\u304b\u3051\u308b\u304b\u3082\u3057\u308c\u307e\u305b\u3093\u3002\u307e\u3060\u3053\u306e\u3088\u3046\u306a\u7121\u9650\u30eb\u30fc\u30d7\u3092\u4f5c\u6210\u3059\u308b\u3053\u3068\u306f\u3067\u304d\u307e\u3059\u304c\u3001\u30bf\u30a4\u30de\u30fc\u30bf\u30b9\u30af\u306a\u3069\u306e\u9023\u7d9a\u5b9f\u884c\u30bf\u30b9\u30af\u3092\u4f5c\u6210\u3059\u308b\u305f\u3081\u306e\u3088\u308a\u826f\u3044\u65b9\u6cd5\u304c\u3042\u308a\u307e\u3059\u3002\u30bf\u30a4\u30de\u30fc\u30bf\u30b9\u30af\u306e\u65b9\u304c\u6d17\u7df4\u3055\u308c\u3066\u304a\u308a\u3001\u3088\u308a\u591a\u304f\u306e\u30aa\u30d7\u30b7\u30e7\u30f3\u3092\u63d0\u4f9b\u3057\u3066\u3044\u308b\u305f\u3081\u3001\u30bf\u30a4\u30de\u30fc\u30bf\u30b9\u30af\u304c\u63a8\u5968\u3055\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u6b8b\u5ff5\u306a\u304c\u3089\u3001\u7121\u9650\u30eb\u30fc\u30d7\u306f\u6642\u306b\u610f\u56f3\u3055\u308c\u3066\u3044\u306a\u3044\u3053\u3068\u3082\u3042\u308a\u307e\u3059\u3002\u9593\u9055\u3044\u3092\u3057\u3066\u7121\u9650\u30eb\u30fc\u30d7\u3092\u5f15\u304d\u8d77\u3053\u3059\u3053\u3068\u304c\u3042\u308a\u307e\u3059\u3002\u4ee5\u4e0b\u306e\u30b3\u30fc\u30c9\u3092\u8003\u3048\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<ol>\n<li data-prefix=\"1\">int x = 3;<\/li>\n<li data-prefix=\"2\"><mark>while<\/mark> (x &gt; 0) {<\/li>\n<li data-prefix=\"3\">System.out.println(&#8220;x is &#8221; + x);<\/li>\n<li data-prefix=\"4\">}<\/li>\n<\/ol>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>&nbsp;<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>\u4e0a\u8a18\u306e\u30b3\u30fc\u30c9\u306f\u3001\u3053\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u306e\u6700\u521d\u306e\u4f8b\u3068\u975e\u5e38\u306b\u4f3c\u3066\u3044\u307e\u3059\u3002\u6700\u521d\u306e\u884c\u3067\u306f\u3001\u5909\u6570x\u3092\u50243\u3067\u5b9a\u7fa9\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>2\u884c\u76ee\u306b\u306fwhile\u30ad\u30fc\u30ef\u30fc\u30c9\u3068\u5236\u5fa1\u6761\u4ef6\u304c\u3042\u308a\u3001\u305d\u308c\u306f\u30eb\u30fc\u30d7\u304cx &gt; 0\u304c\u771f\u3067\u3042\u308b\u9650\u308a\u7d9a\u304f\u3079\u304d\u3067\u3042\u308b\u3053\u3068\u3092\u793a\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>3\u884c\u76ee\u306e System.out.println(&#8220;x is &#8221; + x); \u3068\u3044\u3046\u6587\u306f\u3001println() \u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3057\u3066 x \u306e\u5024\u3092\u51fa\u529b\u3057\u307e\u3059\u3002\u3057\u304b\u3057\u3001\u3053\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u306e\u6700\u521d\u306e\u30bb\u30af\u30b7\u30e7\u30f3\u3067\u306e while \u30eb\u30fc\u30d7\u306e\u4f8b\u3068\u306f\u7570\u306a\u308a\u3001\u73fe\u5728\u306e\u4f8b\u3067\u306f x \u306e\u5f8c\u7f6e\u6e1b\u7b97\u64cd\u4f5c\u304c\u3042\u308a\u307e\u305b\u3093\u3002\u305d\u306e\u305f\u3081\u3001\u3053\u306e\u30eb\u30fc\u30d7\u3092 jshell \u3067\u5b9f\u884c\u3059\u308b\u3068\u3001\u6b21\u306e\u3088\u3046\u306a\u9023\u7d9a\u3057\u305f\u51fa\u529b\u304c\u5f97\u3089\u308c\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<div class=\"secondary-code-label\" title=\"Output\">Output<\/div>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>x is 3 x is 3 &#8230;<\/p>\n<pre class=\"post-pre\"><code><\/code><\/pre>\n<p>\u3053\u306e\u884c\u306f\u3001CTRL+C\u3067\u30eb\u30fc\u30d7\u3092\u7d42\u4e86\u3059\u308b\u307e\u3067\u7121\u9650\u306b\u7e70\u308a\u8fd4\u3055\u308c\u307e\u3059\u3002\u3053\u308c\u3089\u306e\u610f\u56f3\u3057\u306a\u3044\u7121\u9650\u30eb\u30fc\u30d7\u306f\u3001\u30d7\u30ed\u30b0\u30e9\u30e0\u306e\u30af\u30e9\u30c3\u30b7\u30e5\u3084\u30d7\u30ed\u30b0\u30e9\u30e0\u3092\u5b9f\u884c\u3057\u3066\u3044\u308b\u30de\u30b7\u30f3\u306e\u904e\u8ca0\u8377\u3092\u5f15\u304d\u8d77\u3053\u3059\u53ef\u80fd\u6027\u304c\u3042\u308b\u305f\u3081\u3001\u5371\u967a\u3067\u3059\u3002\u305d\u306e\u305f\u3081\u3001\u30eb\u30fc\u30d7\u3092\u4f5c\u6210\u3059\u308b\u969b\u306b\u306f\u6ce8\u610f\u3057\u3066\u3001\u7d42\u4e86\u53ef\u80fd\u306a\u7d42\u4e86\u6761\u4ef6\u304c\u3042\u308b\u3053\u3068\u3092\u78ba\u8a8d\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u73fe\u5728\u306e\u4f8b\u3067\u306f\u3001\u30eb\u30fc\u30d7\u3092\u7d42\u4e86\u3059\u308b\u305f\u3081\u306b\u3001\u5404\u30eb\u30fc\u30d7\u3067x\u304c\u6e1b\u5c11\u3059\u308b\u3088\u3046\u306b\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n<h2>\u7d50\u8ad6<\/h2>\n<p>\u3053\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u3067\u306f\u3001\u7e70\u308a\u8fd4\u3057\u30bf\u30b9\u30af\u3092\u4f5c\u6210\u3059\u308b\u305f\u3081\u306b\u30eb\u30fc\u30d7\u69cb\u9020\u3092\u4f7f\u7528\u3057\u307e\u3057\u305f\u3002while\u30eb\u30fc\u30d7\u3068for\u30eb\u30fc\u30d7\u3092\u4f7f\u7528\u3059\u308b\u9069\u5207\u306a\u5834\u9762\u3068\u3001\u305d\u308c\u3089\u3092\u4f7f\u3063\u305f\u3044\u304f\u3064\u304b\u306e\u30b3\u30fc\u30c9\u4f8b\u3092\u5b66\u3073\u307e\u3057\u305f\u3002\u307e\u305f\u3001\u30af\u30ea\u30fc\u30f3\u306a\u30b3\u30fc\u30c9\u306e\u305f\u3081\u306e\u30d9\u30b9\u30c8\u30d7\u30e9\u30af\u30c6\u30a3\u30b9\u3084\u30eb\u30fc\u30d7\u306b\u95a2\u9023\u3059\u308b\u4e00\u822c\u7684\u306a\u843d\u3068\u3057\u7a74\u3092\u907f\u3051\u308b\u65b9\u6cd5\u3082\u5b66\u3073\u307e\u3057\u305f\u3002<\/p>\n<p>Java\u306b\u3064\u3044\u3066\u3082\u3063\u3068\u8a73\u3057\u304f\u77e5\u308a\u305f\u3044\u5834\u5408\u306f\u3001\u79c1\u305f\u3061\u306e\u300cJava\u3067\u306e\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0\u65b9\u6cd5\u300d\u30b7\u30ea\u30fc\u30ba\u3092\u3054\u89a7\u304f\u3060\u3055\u3044\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u8457\u8005\u306f\u5bc4\u4ed8\u30d7\u30ed\u30b0\u30e9\u30e0\u300cWrite for Donations\u300d\u306e\u4e00\u74b0\u3068\u3057\u3066\u3001\u30d5\u30ea\u30fc\u304a\u3088\u3073\u30aa\u30fc\u30d7\u30f3\u30bd\u30fc\u30b9\u57fa\u91d1\u3092\u9078\u3093\u3067\u5bc4\u4ed8\u3059\u308b\u3053\u3068\u306b\u3057\u307e\u3057\u305f\u3002 \u306f\u3058\u3081\u306b \u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u3067\u306f\u3001\u53cd\u5fa9\u7684\u306a\u30bf\u30b9\u30af\u3092\u66f8\u304f\u3053\u3068\u306f\u4e00\u822c\u7684\u3067\u3059\u3002\u540c\u3058\u307e\u305f\u306f\u985e [&hellip;]<\/p>\n","protected":false},"author":12,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[26,61],"class_list":["post-63","post","type-post","status-publish","format-standard","hentry","category-uncategorized","tag-26","tag-61"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v21.5 (Yoast SEO v21.5) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5 - Blog - Silicon Cloud<\/title>\n<meta name=\"description\" content=\"Java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5\u3092\u5206\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\u3002\u5b9f\u8df5\u7684\u306a\u4f8b\u3068\u30b3\u30fc\u30c9\u3001\u6ce8\u610f\u70b9\u3092\u542b\u3081\u3066\u521d\u5fc3\u8005\u306b\u3082\u7406\u89e3\u3067\u304d\u308b\u3088\u3046\u8aac\u660e\u3057\u307e\u3059\u3002\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.silicloud.com\/ja\/blog\/java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5\/\" \/>\n<meta property=\"og:locale\" content=\"ja_JP\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5\" \/>\n<meta property=\"og:description\" content=\"Java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5\u3092\u5206\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\u3002\u5b9f\u8df5\u7684\u306a\u4f8b\u3068\u30b3\u30fc\u30c9\u3001\u6ce8\u610f\u70b9\u3092\u542b\u3081\u3066\u521d\u5fc3\u8005\u306b\u3082\u7406\u89e3\u3067\u304d\u308b\u3088\u3046\u8aac\u660e\u3057\u307e\u3059\u3002\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.silicloud.com\/ja\/blog\/java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5\/\" \/>\n<meta property=\"og:site_name\" content=\"Blog - Silicon Cloud\" \/>\n<meta property=\"article:published_time\" content=\"2023-01-04T20:56:22+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-07-31T04:45:39+00:00\" \/>\n<meta name=\"author\" content=\"\u5149, \u660e\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u57f7\u7b46\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"\u5149, \u660e\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u63a8\u5b9a\u8aad\u307f\u53d6\u308a\u6642\u9593\" \/>\n\t<meta name=\"twitter:data2\" content=\"22\u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%a7%e3%83%ab%e3%83%bc%e3%83%97%e3%82%92%e4%bd%bf%e3%81%86%e6%96%b9%e6%b3%95\/\",\"url\":\"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%a7%e3%83%ab%e3%83%bc%e3%83%97%e3%82%92%e4%bd%bf%e3%81%86%e6%96%b9%e6%b3%95\/\",\"name\":\"Java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5 - Blog - Silicon Cloud\",\"isPartOf\":{\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/#website\"},\"datePublished\":\"2023-01-04T20:56:22+00:00\",\"dateModified\":\"2025-07-31T04:45:39+00:00\",\"author\":{\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/9ee62cea876d247deba14a0ac7ba5b55\"},\"description\":\"Java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5\u3092\u5206\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\u3002\u5b9f\u8df5\u7684\u306a\u4f8b\u3068\u30b3\u30fc\u30c9\u3001\u6ce8\u610f\u70b9\u3092\u542b\u3081\u3066\u521d\u5fc3\u8005\u306b\u3082\u7406\u89e3\u3067\u304d\u308b\u3088\u3046\u8aac\u660e\u3057\u307e\u3059\u3002\",\"breadcrumb\":{\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%a7%e3%83%ab%e3%83%bc%e3%83%97%e3%82%92%e4%bd%bf%e3%81%86%e6%96%b9%e6%b3%95\/#breadcrumb\"},\"inLanguage\":\"ja\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%a7%e3%83%ab%e3%83%bc%e3%83%97%e3%82%92%e4%bd%bf%e3%81%86%e6%96%b9%e6%b3%95\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%a7%e3%83%ab%e3%83%bc%e3%83%97%e3%82%92%e4%bd%bf%e3%81%86%e6%96%b9%e6%b3%95\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.silicloud.com\/ja\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/#website\",\"url\":\"https:\/\/www.silicloud.com\/ja\/blog\/\",\"name\":\"Blog - Silicon Cloud\",\"description\":\"\",\"inLanguage\":\"ja\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/9ee62cea876d247deba14a0ac7ba5b55\",\"name\":\"\u5149, \u660e\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/3dffb6c754b95e3fbdcd8973f4375ff9dd10d41e4f6632ad08d4d59ccc35af8d?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/3dffb6c754b95e3fbdcd8973f4375ff9dd10d41e4f6632ad08d4d59ccc35af8d?s=96&d=mm&r=g\",\"caption\":\"\u5149, \u660e\"},\"url\":\"https:\/\/www.silicloud.com\/ja\/blog\/author\/hikariakira\/\"},{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%a7%e3%83%ab%e3%83%bc%e3%83%97%e3%82%92%e4%bd%bf%e3%81%86%e6%96%b9%e6%b3%95\/#local-main-organization-logo\",\"url\":\"\",\"contentUrl\":\"\",\"caption\":\"Blog - Silicon Cloud\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5 - Blog - Silicon Cloud","description":"Java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5\u3092\u5206\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\u3002\u5b9f\u8df5\u7684\u306a\u4f8b\u3068\u30b3\u30fc\u30c9\u3001\u6ce8\u610f\u70b9\u3092\u542b\u3081\u3066\u521d\u5fc3\u8005\u306b\u3082\u7406\u89e3\u3067\u304d\u308b\u3088\u3046\u8aac\u660e\u3057\u307e\u3059\u3002","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.silicloud.com\/ja\/blog\/java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5\/","og_locale":"ja_JP","og_type":"article","og_title":"Java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5","og_description":"Java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5\u3092\u5206\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\u3002\u5b9f\u8df5\u7684\u306a\u4f8b\u3068\u30b3\u30fc\u30c9\u3001\u6ce8\u610f\u70b9\u3092\u542b\u3081\u3066\u521d\u5fc3\u8005\u306b\u3082\u7406\u89e3\u3067\u304d\u308b\u3088\u3046\u8aac\u660e\u3057\u307e\u3059\u3002","og_url":"https:\/\/www.silicloud.com\/ja\/blog\/java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5\/","og_site_name":"Blog - Silicon Cloud","article_published_time":"2023-01-04T20:56:22+00:00","article_modified_time":"2025-07-31T04:45:39+00:00","author":"\u5149, \u660e","twitter_card":"summary_large_image","twitter_misc":{"\u57f7\u7b46\u8005":"\u5149, \u660e","\u63a8\u5b9a\u8aad\u307f\u53d6\u308a\u6642\u9593":"22\u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%a7%e3%83%ab%e3%83%bc%e3%83%97%e3%82%92%e4%bd%bf%e3%81%86%e6%96%b9%e6%b3%95\/","url":"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%a7%e3%83%ab%e3%83%bc%e3%83%97%e3%82%92%e4%bd%bf%e3%81%86%e6%96%b9%e6%b3%95\/","name":"Java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5 - Blog - Silicon Cloud","isPartOf":{"@id":"https:\/\/www.silicloud.com\/ja\/blog\/#website"},"datePublished":"2023-01-04T20:56:22+00:00","dateModified":"2025-07-31T04:45:39+00:00","author":{"@id":"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/9ee62cea876d247deba14a0ac7ba5b55"},"description":"Java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5\u3092\u5206\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\u3002\u5b9f\u8df5\u7684\u306a\u4f8b\u3068\u30b3\u30fc\u30c9\u3001\u6ce8\u610f\u70b9\u3092\u542b\u3081\u3066\u521d\u5fc3\u8005\u306b\u3082\u7406\u89e3\u3067\u304d\u308b\u3088\u3046\u8aac\u660e\u3057\u307e\u3059\u3002","breadcrumb":{"@id":"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%a7%e3%83%ab%e3%83%bc%e3%83%97%e3%82%92%e4%bd%bf%e3%81%86%e6%96%b9%e6%b3%95\/#breadcrumb"},"inLanguage":"ja","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%a7%e3%83%ab%e3%83%bc%e3%83%97%e3%82%92%e4%bd%bf%e3%81%86%e6%96%b9%e6%b3%95\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%a7%e3%83%ab%e3%83%bc%e3%83%97%e3%82%92%e4%bd%bf%e3%81%86%e6%96%b9%e6%b3%95\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.silicloud.com\/ja\/blog\/"},{"@type":"ListItem","position":2,"name":"Java\u3067\u30eb\u30fc\u30d7\u3092\u4f7f\u3046\u65b9\u6cd5"}]},{"@type":"WebSite","@id":"https:\/\/www.silicloud.com\/ja\/blog\/#website","url":"https:\/\/www.silicloud.com\/ja\/blog\/","name":"Blog - Silicon Cloud","description":"","inLanguage":"ja"},{"@type":"Person","@id":"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/9ee62cea876d247deba14a0ac7ba5b55","name":"\u5149, \u660e","image":{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/3dffb6c754b95e3fbdcd8973f4375ff9dd10d41e4f6632ad08d4d59ccc35af8d?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/3dffb6c754b95e3fbdcd8973f4375ff9dd10d41e4f6632ad08d4d59ccc35af8d?s=96&d=mm&r=g","caption":"\u5149, \u660e"},"url":"https:\/\/www.silicloud.com\/ja\/blog\/author\/hikariakira\/"},{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%a7%e3%83%ab%e3%83%bc%e3%83%97%e3%82%92%e4%bd%bf%e3%81%86%e6%96%b9%e6%b3%95\/#local-main-organization-logo","url":"","contentUrl":"","caption":"Blog - Silicon Cloud"}]}},"_links":{"self":[{"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/posts\/63","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/users\/12"}],"replies":[{"embeddable":true,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/comments?post=63"}],"version-history":[{"count":1,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/posts\/63\/revisions"}],"predecessor-version":[{"id":35950,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/posts\/63\/revisions\/35950"}],"wp:attachment":[{"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/media?parent=63"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/categories?post=63"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/tags?post=63"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}