Core Java code