Sample Java Codes