Sunday, April 28, 2013

Tutorial 4: char, boolean data types


Tutorial 4: char, boolean data types

Code: 

PrimitiveDataType.java 

package tutorial;


public class PrimitiveDataType {
    public static void main(String[] args) {
        //UNICODE = 65535;
        char chChar = 'A';
        System.out.println("our char variable is holding the value:"+chChar);
        boolean booFalse = true;
        System.out.println("our varible of type boolean is:" + booFalse);
        //int, float, double, long, char, boolean - primitive datatypes
    }
}

No comments:

Post a Comment