title: how can i display a message dialog box in java
body: <p>i want to display a message dialog box in java. At this moment i can only display a message in a console by using <code>System.out.println()</code> method </p>
  
  <p>Example :   </p>
  
  <pre><code>public class demo{
          public static void main(String[] x){
             // i want to display the below message in a dialog box
             System.out.print("java is fun"); 
  
           }
        }  
  </code></pre>