<pre><code class="language-java">/* CallingMethodsInSameClass.java * * illustrates how to call static methods a class * from a method in the same class */ public class CallingMethodsInSameClass { public static void main(String[] args) { printOne(); } public static void printOne() { System.out.println("Hello World"); } }</code></pre>
댓글 없음:
댓글 쓰기