November 27, 2013

Published November 27, 2013 by

Read password (hidden) from Console

Generally all the texts given as input in a Java console application are visible. When we read a password from a Java console application, it will not be wise to display the input password. If we want to hide the password, we can use the readPassword method java.io.Console class...
Read More

November 24, 2013

Published November 24, 2013 by

Java Variables

Variable is the named location of memory. Variable is used to store data, that’s why this is called the unit of storage. A value of a variable can be modified during the course of program execution. In Java, you must explicitly declare all variables before using them.Variable declaration includes:Data typeVariable nameInitial value (optional)A ; (semi colon) at the end of declaration statement.Syntax...
Read More
Published November 24, 2013 by

Java Data Types

Data Types: A data type or simply type is a classification identifying one of various types of data, such as whole numbers or fractional numbers.Data Type determines:the possible values for that typethe operations that can be done on values of that typethe meaning of the datathe way values of that type can be storedJava is a strongly typed language because when you declare a variable,...
Read More