dairy program using java