Create distance.java