import java.util.Arrays;
import java.util.Scanner;

public class Main {

	@SuppressWarnings("resource")
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);
		int a[]=new int [3];
		a[0]=scanner.nextInt();
		a[1]=scanner.nextInt();
		a[2]=scanner.nextInt();
		Arrays.sort(a);
		
		System.out.println((a[2]-a[1])+a[1]-a[0]);
	}
} import java.util.Arrays; Arrays java.util import java.util.Scanner; Scanner java.util public class Main {

	@SuppressWarnings("resource")
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);
		int a[]=new int [3];
		a[0]=scanner.nextInt();
		a[1]=scanner.nextInt();
		a[2]=scanner.nextInt();
		Arrays.sort(a);
		
		System.out.println((a[2]-a[1])+a[1]-a[0]);
	}
} Main @SuppressWarnings("resource")
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);
		int a[]=new int [3];
		a[0]=scanner.nextInt();
		a[1]=scanner.nextInt();
		a[2]=scanner.nextInt();
		Arrays.sort(a);
		
		System.out.println((a[2]-a[1])+a[1]-a[0]);
	} main {
		Scanner scanner = new Scanner(System.in);
		int a[]=new int [3];
		a[0]=scanner.nextInt();
		a[1]=scanner.nextInt();
		a[2]=scanner.nextInt();
		Arrays.sort(a);
		
		System.out.println((a[2]-a[1])+a[1]-a[0]);
	} Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int a[]=new int [3]; a new int [3] 3 a[0]=scanner.nextInt() a[0] a 0 scanner.nextInt() scanner.nextInt scanner a[1]=scanner.nextInt() a[1] a 1 scanner.nextInt() scanner.nextInt scanner a[2]=scanner.nextInt() a[2] a 2 scanner.nextInt() scanner.nextInt scanner Arrays.sort(a) Arrays.sort Arrays a System.out.println((a[2]-a[1])+a[1]-a[0]) System.out.println System.out System System.out (a[2]-a[1])+a[1]-a[0] (a[2]-a[1])+a[1] (a[2]-a[1]) a[2] a 2 a[1] a 1 a[1] a 1 a[0] a 0 String args[] args public class Main {

	@SuppressWarnings("resource")
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);
		int a[]=new int [3];
		a[0]=scanner.nextInt();
		a[1]=scanner.nextInt();
		a[2]=scanner.nextInt();
		Arrays.sort(a);
		
		System.out.println((a[2]-a[1])+a[1]-a[0]);
	}
} public class Main {

	@SuppressWarnings("resource")
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);
		int a[]=new int [3];
		a[0]=scanner.nextInt();
		a[1]=scanner.nextInt();
		a[2]=scanner.nextInt();
		Arrays.sort(a);
		
		System.out.println((a[2]-a[1])+a[1]-a[0]);
	}
} Main
import java.util.Arrays;
import java.util.Scanner;

public class Main {

	@SuppressWarnings("resource")
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);
		int a[]=new int [3];
		a[0]=scanner.nextInt();
		a[1]=scanner.nextInt();
		a[2]=scanner.nextInt();
		Arrays.sort(a);
		
		System.out.println((a[2]-a[1])+a[1]-a[0]);
	}
}
