Introductory programs in Java