Basic practice with Java