import java.util.*; public class distance{ public static int calculate_max(int[] A){ return A[A.length-1] - A[0]; } public static int calculate_min(int[] A){ int min_dis = calculate_max(A); try{ for (int i = 0; i