Java part 1