import java.util.Scanner;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int x = a;
		int b = sc.nextInt();
		int y = b;
		if(b > a) {
			x = b;
			y = a;
		}
		int c = sc.nextInt();
		int z = c;
		if(c > x) {
			z = y;
			y = x;
			x = c;
		}else if(c > y) {
			z = y;
			y = c;
		}

		System.out.println((x-y)+(y-z));


	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int x = a;
		int b = sc.nextInt();
		int y = b;
		if(b > a) {
			x = b;
			y = a;
		}
		int c = sc.nextInt();
		int z = c;
		if(c > x) {
			z = y;
			y = x;
			x = c;
		}else if(c > y) {
			z = y;
			y = c;
		}

		System.out.println((x-y)+(y-z));


	}
} Main public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int x = a;
		int b = sc.nextInt();
		int y = b;
		if(b > a) {
			x = b;
			y = a;
		}
		int c = sc.nextInt();
		int z = c;
		if(c > x) {
			z = y;
			y = x;
			x = c;
		}else if(c > y) {
			z = y;
			y = c;
		}

		System.out.println((x-y)+(y-z));


	} main {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int x = a;
		int b = sc.nextInt();
		int y = b;
		if(b > a) {
			x = b;
			y = a;
		}
		int c = sc.nextInt();
		int z = c;
		if(c > x) {
			z = y;
			y = x;
			x = c;
		}else if(c > y) {
			z = y;
			y = c;
		}

		System.out.println((x-y)+(y-z));


	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc int x = a; x a int b = sc.nextInt(); b sc.nextInt() sc.nextInt sc int y = b; y b if(b > a) {
			x = b;
			y = a;
		} b > a b a {
			x = b;
			y = a;
		} x = b x b y = a y a int c = sc.nextInt(); c sc.nextInt() sc.nextInt sc int z = c; z c if(c > x) {
			z = y;
			y = x;
			x = c;
		}else if(c > y) {
			z = y;
			y = c;
		} c > x c x {
			z = y;
			y = x;
			x = c;
		} z = y z y y = x y x x = c x c if(c > y) {
			z = y;
			y = c;
		} c > y c y {
			z = y;
			y = c;
		} z = y z y y = c y c System.out.println((x-y)+(y-z)) System.out.println System.out System System.out (x-y)+(y-z) (x-y) x y (y-z) y z String[] args args public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int x = a;
		int b = sc.nextInt();
		int y = b;
		if(b > a) {
			x = b;
			y = a;
		}
		int c = sc.nextInt();
		int z = c;
		if(c > x) {
			z = y;
			y = x;
			x = c;
		}else if(c > y) {
			z = y;
			y = c;
		}

		System.out.println((x-y)+(y-z));


	}
} public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int x = a;
		int b = sc.nextInt();
		int y = b;
		if(b > a) {
			x = b;
			y = a;
		}
		int c = sc.nextInt();
		int z = c;
		if(c > x) {
			z = y;
			y = x;
			x = c;
		}else if(c > y) {
			z = y;
			y = c;
		}

		System.out.println((x-y)+(y-z));


	}
} Main
import java.util.Scanner;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int x = a;
		int b = sc.nextInt();
		int y = b;
		if(b > a) {
			x = b;
			y = a;
		}
		int c = sc.nextInt();
		int z = c;
		if(c > x) {
			z = y;
			y = x;
			x = c;
		}else if(c > y) {
			z = y;
			y = c;
		}

		System.out.println((x-y)+(y-z));


	}
}