My Java code