Coding Experiments in java