Some sample applications in java