import java.util.*;
public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int cost[] = new int[3];
		for(int i = 0; i < 3; i ++) {
			cost[i] = sc.nextInt();
		}
		Arrays.sort(cost);
		System.out.println(Math.abs(cost[0] - cost[2]));
	}
} import java.util.*; util.* java public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int cost[] = new int[3];
		for(int i = 0; i < 3; i ++) {
			cost[i] = sc.nextInt();
		}
		Arrays.sort(cost);
		System.out.println(Math.abs(cost[0] - cost[2]));
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int cost[] = new int[3];
		for(int i = 0; i < 3; i ++) {
			cost[i] = sc.nextInt();
		}
		Arrays.sort(cost);
		System.out.println(Math.abs(cost[0] - cost[2]));
	} main {
		Scanner sc = new Scanner(System.in);
		int cost[] = new int[3];
		for(int i = 0; i < 3; i ++) {
			cost[i] = sc.nextInt();
		}
		Arrays.sort(cost);
		System.out.println(Math.abs(cost[0] - cost[2]));
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int cost[] = new int[3]; cost new int[3] 3 for(int i = 0; i < 3; i ++) {
			cost[i] = sc.nextInt();
		} int i = 0; int i = 0; i 0 i < 3 i 3 i ++ i ++ i {
			cost[i] = sc.nextInt();
		} {
			cost[i] = sc.nextInt();
		} cost[i] = sc.nextInt() cost[i] cost i sc.nextInt() sc.nextInt sc Arrays.sort(cost) Arrays.sort Arrays cost System.out.println(Math.abs(cost[0] - cost[2])) System.out.println System.out System System.out Math.abs(cost[0] - cost[2]) Math.abs Math cost[0] - cost[2] cost[0] cost 0 cost[2] cost 2 String[] args args public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int cost[] = new int[3];
		for(int i = 0; i < 3; i ++) {
			cost[i] = sc.nextInt();
		}
		Arrays.sort(cost);
		System.out.println(Math.abs(cost[0] - cost[2]));
	}
} public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int cost[] = new int[3];
		for(int i = 0; i < 3; i ++) {
			cost[i] = sc.nextInt();
		}
		Arrays.sort(cost);
		System.out.println(Math.abs(cost[0] - cost[2]));
	}
} Main
import java.util.*;
public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int cost[] = new int[3];
		for(int i = 0; i < 3; i ++) {
			cost[i] = sc.nextInt();
		}
		Arrays.sort(cost);
		System.out.println(Math.abs(cost[0] - cost[2]));
	}
}