MainClass.java Source code

Java tutorial

Introduction

Here is the source code for MainClass.java

Source

/*
 * Output:
     
i1 = 5
i2 = 6
    
    
    
 */

public class MainClass {
    public static void main(String args[]) {
        Integer iobj1 = new Integer(5);
        Integer iobj2 = new Integer("6");
        int i1 = iobj1.intValue();
        int i2 = iobj2.intValue();
        System.out.println("i1 = " + i1);
        System.out.println("i2 = " + i2);
    }
}