Wednesday, 30 September 2015

Java Tutorial : Java Boolean Literals


Click here to watch in Youtube :
https://www.youtube.com/watch?v=5p86AYeM12s&list=UUhwKlOVR041tngjerWxVccw

Click the below Image to Enlarge
Java Tutorial : Java Boolean Literals 
IntegerLiteralDemo.java
public class IntegerLiteralDemo
{

    public static void main(String[] args)
    {

        boolean flag = true;

        System.out.println("flag : " + flag);

        boolean isSmartTv = false;

        System.out.println("isSmartTv : " + isSmartTv);
    }
}
Output
flag : true
isSmartTv : false
To Download VariableDemoBooleanLiteralApp Project Click the below link
https://sites.google.com/site/javaee4321/java/VariableDemoBooleanLiteralApp.zip?attredirects=0&d=1

See also:
  • All JavaEE Viedos Playlist
  • All JavaEE Viedos
  • All JAVA EE Links
  • Servlets Tutorial
  • All Design Patterns Links
  • JDBC Tutorial
  • Java Collection Framework Tutorial
  • JAVA Tutorial
  • Java Tutorial : Java String Literals


    Click here to watch in Youtube :
    https://www.youtube.com/watch?v=IuiyhgFN-vg&list=UUhwKlOVR041tngjerWxVccw

    Click the below Image to Enlarge
    Java Tutorial : Java String Literals
    Java Tutorial : Java String Literals
    StringLiteralDemo.java
    public class StringLiteralDemo
    {
    
        public static void main(String[] args)
        {
    
            String quitMsg = "Are you sure you want to quit?";
    
            System.out.println("quitMsg : " + quitMsg);
    
            String password = "swordfish";
    
            System.out.println("password : " + password);
    
            String value = "Ram asked, \"How are you?\"";
    
            System.out.println("value : " + value);
    
            System.out.println("hi,\n Welcome\n");
    
            String title = "Sams Teach Yourself Java While You Sleep\u2122";
    
            System.out.println("title : " + title);
    
        }
    
    }
    
    Output
    quitMsg : Are you sure you want to quit?
    password : swordfish
    value : Ram asked, "How are you?"
    hi,
     Welcome
    
    title : Sams Teach Yourself Java While You Sleep™
    
    To Download VariableDemoStringLiteralApp Project Click the below link
    https://sites.google.com/site/javaee4321/java/VariableDemoStringLiteralApp.zip?attredirects=0&d=1

    See also:
  • All JavaEE Viedos Playlist
  • All JavaEE Viedos
  • All JAVA EE Links
  • Servlets Tutorial
  • All Design Patterns Links
  • JDBC Tutorial
  • Java Collection Framework Tutorial
  • JAVA Tutorial
  • Monday, 28 September 2015

    Java Tutorial : Java Integer Literal with underscore


    Click here to watch in Youtube :
    https://www.youtube.com/watch?v=104IHkkGZms&list=UUhwKlOVR041tngjerWxVccw

    Click the below Image to Enlarge
    Java Tutorial : Java Integer Literal with underscore
    Java Tutorial : Java Integer Literal with underscore
    IntegerLiteralDemo.java
    public class IntegerLiteralDemo
    {
    
        public static void main(String[] args)
        {
    
            int number = 901_306_555;
    
            System.out.println("number : " + number);
    
            int octalLiteral = 045_23;
    
            System.out.println("octalLiteral : " + octalLiteral);
    
            int hexadecimalLiteral = 0x55_21;
    
            System.out.println("hexadecimalLiteral : " + hexadecimalLiteral);
    
            int binaryLiteral = 0b1000_1001;
    
            System.out.println("binaryLiteral : " + binaryLiteral);
    
        }
    }
    
    Output
    number : 901306555
    octalLiteral : 2387
    hexadecimalLiteral : 21793
    binaryLiteral : 137
    
    To Download VariableDemoIntegerLiteralWithUnderScoreApp Project Click the below link
    https://sites.google.com/site/javaee4321/java/VariableDemoIntegerLiteralWithUnderScoreApp.zip?attredirects=0&d=1

    See also:

  • All JavaEE Viedos Playlist
  • All JavaEE Viedos
  • All JAVA EE Links
  • Servlets Tutorial
  • All Design Patterns Links
  • JDBC Tutorial
  • Java Collection Framework Tutorial
  • JAVA Tutorial
  • Java Tutorial : Integer Literals in Java


    Click here to watch in Youtube :
    https://www.youtube.com/watch?v=dD8Uwn2_EmE&list=UUhwKlOVR041tngjerWxVccw

    Click the below Image to Enlarge

    IntegerLiteralDemo.java
    public class IntegerLiteralDemo
    {
    
        public static void main(String[] args)
        {
    
            int num = 10;
    
            System.out.println("num : " + num);
    
            num = 010;
    
            System.out.println("num : " + num);
    
            num = 0x10;
    
            System.out.println("num : " + num);
    
            num = 0b1010;
    
            System.out.println("num : " + num);
    
            long number = 599L;
    
            System.out.println("number : " + number);
    
        }
    }
    
    Output
    num : 10
    num : 8
    num : 16
    num : 10
    number : 599
    
    To Download VariableDemoIntergerLiteralsInJavaApp Project Click the below link
    https://sites.google.com/site/javaee4321/java/VariableDemoIntergerLiteralsInJavaApp.zip?attredirects=0&d=1

    See also:
  • All JavaEE Viedos Playlist
  • All JavaEE Viedos
  • All JAVA EE Links
  • Servlets Tutorial
  • All Design Patterns Links
  • JDBC Tutorial
  • Java Collection Framework Tutorial
  • JAVA Tutorial
  • Java Tutorial : Java Variable Type Conversion && Type Casting - Playlist

    Java Tutorial : Java Integer Literals


    Click here to watch in Youtube :
    https://www.youtube.com/watch?v=6GriFQkmhB4&list=UUhwKlOVR041tngjerWxVccw

    Click the below Image to Enlarge
    Java Tutorial : Java Integer Literals
    Java Tutorial : Java Integer Literals



    Java Tutorial : Java Integer Literals 
    IntegerLiteralDemo.java
    public class IntegerLiteralDemo
    {
    
        public static void main(String[] args)
        {
    
            long longValue = 100L;
    
            System.out.println("longValue : " + longValue);
    
            // The number 26, in decimal
            int decVal = 26;
    
            System.out.println("decVal : " + decVal);
    
            // The number 26, in hexadecimal
            int hexVal = 0x1a;
    
            System.out.println("hexVal : " + hexVal);
    
            // The number 26, in binary
            int binVal = 0b11010;
    
            System.out.println("binVal : " + binVal);
    
        }
    }
    
    Output
    longValue : 100
    decVal : 26
    hexVal : 26
    binVal : 26
    
    To Download VariableDemoIntegerLiteralsApp Project Click the below link
    https://sites.google.com/site/javaee4321/java/VariableDemoIntegerLiteralsApp.zip?attredirects=0&d=1

    See also:
  • All JavaEE Viedos Playlist
  • All JavaEE Viedos
  • All JAVA EE Links
  • Servlets Tutorial
  • All Design Patterns Links
  • JDBC Tutorial
  • Java Collection Framework Tutorial
  • JAVA Tutorial
  • Java Tutorial : Java Variable Type Casting


    Click here to watch in Youtube :
    https://www.youtube.com/watch?v=6GriFQkmhB4&list=UUhwKlOVR041tngjerWxVccw

    Click the below Image to Enlarge
    Java Tutorial : Java Variable Type Casting
    Java Tutorial : Java Variable Type Casting
    Java Tutorial : Java Variable Type Casting
    Java Tutorial : Java Variable Type Casting
    Java Tutorial : Java Variable Type Casting
    TypeConversionDemo.java
    public class TypeConversionDemo
    {
    
        public static void main(String[] args)
        {
    
            int intVar = 200;
            /*
             * Variable of smaller capacity is be assigned to another variable of
             * bigger capacity.
             */
    
            long longVar = intVar; // no explicit type casting required
            float floatVar = longVar; // no explicit type casting required
    
            System.out.println("Int value : " + intVar);
            System.out.println("Long value : " + longVar);
            System.out.println("Float value : " + floatVar);
    
        }
    
    }
    
    Output
    Int value : 200
    Long value : 200
    Float value : 200.0
    
    TypeCastDemo.java
    public class TypeCastDemo
    {
    
        public static void main(String[] args)
        {
            double doubleVar = 200000.04;
    
            /*
             * Variable of larger capacity is be assigned to another variable of
             * smaller capacity.
             */
    
            int intVar = (int) doubleVar; // explicit type casting required
            byte byteVar = (byte) intVar; // explicit type casting required
    
            System.out.println("double value " + doubleVar);
            System.out.println("int value " + intVar);
            System.out.println("byte value " + byteVar);
    
        }
    }
    
    Output
    double value 200000.04
    int value 200000
    byte value 64
    
    To Download VariableDemoTypeCastApp Project Click the below link
    https://sites.google.com/site/javaee4321/java/VariableDemoTypeCastApp.zip?attredirects=0&d=1

    See also:

  • All JavaEE Viedos Playlist
  • All JavaEE Viedos
  • All JAVA EE Links
  • Servlets Tutorial
  • All Design Patterns Links
  • JDBC Tutorial
  • Java Collection Framework Tutorial
  • JAVA Tutorial
  • Java Tutorial : Java Variable Type Conversion && Type Casting


    Click here to watch in Youtube :
    https://www.youtube.com/watch?v=5Qa40NrzajQ&list=UUhwKlOVR041tngjerWxVccw

    Click the below Image to Enlarge
    Java Tutorial : Java Variable Type Conversion && Type Casting 
    Java Tutorial : Java Variable Type Conversion && Type Casting 
    Java Tutorial : Java Variable Type Conversion && Type Casting 
    Java Tutorial : Java Variable Type Conversion && Type Casting 

    TypeConversionDemo.java
    public class TypeConversionDemo
    {
    
        public static void main(String[] args)
        {
            double doubleVariable;
            long longVariable;
            int intVariable = 10;
    
            /*
             * Variable of smaller capacity is be assigned to another variable of
             * bigger capacity.
             */
            longVariable = intVariable;
            doubleVariable = intVariable;
    
            System.out.println("longVariable : " + longVariable);
            System.out.println("doubleVariable : " + doubleVariable);
    
        }
    
    }
    
    Output
    longVariable : 10
    doubleVariable : 10.0
    TypeCastDemo.java
    public class TypeCastDemo
    {
    
        public static void main(String[] args)
        {
            double doubleVariable = 2898.9999;
            long longVariable = 199;
            int intVariable;
    
            /*
             * Variable of larger capacity is be assigned to another variable of
             * smaller capacity.
             */
            intVariable = (int) longVariable;
    
            System.out.println("longVariable " + longVariable
                    + " converted to intVariable : " + intVariable);
    
            intVariable = (int) doubleVariable;
    
            System.out.println("doubleVariable " + doubleVariable
                    + " converted to intVariable : " + intVariable);
    
        }
    }
    
    Output
    longVariable 199 converted to intVariable : 199
    doubleVariable 2898.9999 converted to intVariable : 2898
    
    To Download VariableDemoTypeConversionAndCastingApp Project Click the below link
    https://sites.google.com/site/javaee4321/java/VariableDemoTypeConversionAndCastingApp.zip?attredirects=0&d=1

    See also:

  • All JavaEE Viedos Playlist
  • All JavaEE Viedos
  • All JAVA EE Links
  • Servlets Tutorial
  • All Design Patterns Links
  • JDBC Tutorial
  • Java Collection Framework Tutorial
  • JAVA Tutorial
  • Friday, 25 September 2015

    Java Tutorial : Java Literals - Playlist

    Java Tutorial : Java Unicode System - Playlist

    Java Tutorial : Literals in Java

    Java Tutorial : Java Literals

    Java Tutorial : Unicode System in Java

    Java Tutorial : Java Unicode System

    Java Tutorial : Java How to use variables | Java Data Types


    Click here to watch in Youtube :
    https://www.youtube.com/watch?v=H94ePX2Vqu4&list=UUhwKlOVR041tngjerWxVccw

    Click the below Image to Enlarge
    Java Tutorial : Java How to use variables | Java Data Types 
    Java Tutorial : Java How to use variables | Java Data Types 
    Java Tutorial : Java How to use variables | Java Data Types 
    Java Tutorial : Java How to use variables | Java Data Types 
    Java Tutorial : Java How to use variables | Java Data Types 
    Java Tutorial : Java How to use variables | Java Data Types 
    Java Tutorial : Java How to use variables | Java Data Types 
    Java Tutorial : Java How to use variables | Java Data Types 
    See also:
  • All JavaEE Viedos Playlist
  • All JavaEE Viedos
  • All JAVA EE Links
  • Servlets Tutorial
  • All Design Patterns Links
  • JDBC Tutorial
  • Java Collection Framework Tutorial
  • JAVA Tutorial
  • Google+ Followers

    Google+ Badge