
import java.io.*;
import java.math.*;
import java.util.*;
public class Main {  
 
	public static void main(String[] args) { 
		FastScanner I = new FastScanner(); //Input
		OutPut O = new OutPut(); //Output
		int Z = 0;
		int ONE = 0;
		String S = I.next();
		for (int i = 0; i < S.length(); i++) {
			if (S.charAt(i)=='0') Z++;
			else ONE++;
		}
		O.pln(Math.min(ONE, Z)*2);
	}
	public static ArrayList<String> perms(int N, int upper){
		if (N==1) {
			ArrayList<String> ret = new ArrayList<String>();
			for (int i = 1; i<=upper; i++) ret.add(Integer.toString(i)+" ");
			return ret;
		}
		ArrayList<String> prev = perms(N-1,upper);
		ArrayList<String> ret = new ArrayList<String>();
		for (int i = 0; i < prev.size(); i++) {
			boolean[] vis = new boolean[upper+1];
			String cur = prev.get(i);
			String[] parts = cur.split(" ");
			for (int j = 0; j < parts.length; j++) {
				vis[Integer.parseInt(parts[j])]=true;
			}
			for (int j = 1; j <= upper; j++) {
				if (!vis[j]) {
					String curans = cur;
					curans+=Integer.toString(j)+" ";
					ret.add(curans);
				}
			}
		}
		return ret;
	}
	public static long ceil(long num, long den) {long ans = num/den; if (num%den!=0) 
	ans++; return ans;}
	public static long GCD(long a, long b) {
		if (a==0||b==0) return Math.max(a,b);
		return GCD(Math.min(a, b),Math.max(a, b)%Math.min(a, b));
	}
	public static long FastExp(long base, long exp, long mod) {
		long ans=1;
		while (exp>0) {
			if (exp%2==1) ans*=base;
			exp/=2;
			base*=base;
			base%=mod;
			ans%=mod;
		}
		return ans;
	}
	public static long ModInv(long num,long mod) {return FastExp(num,mod-2,mod);}
	public static int pop(long x) { //Returns number of bits within a number
		int cnt = 0;
		while (x>0) {
			if (x%2==1) cnt++;
			x/=2;
		}
		return cnt;
	}
	static class FastScanner {
		BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st=new StringTokenizer("");
		String next() {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		}
		int nextInt() {return Integer.parseInt(next());}
		long nextLong() {return Long.parseLong(next());};
		double nextDouble() {return Double.parseDouble(next());}
	}
	static class OutPut{
		PrintWriter w = new PrintWriter(System.out);
		void pln(double x) {w.println(x);w.flush();}
		void pln(boolean x) {w.println(x);w.flush();}
		void pln(int x) {w.println(x);w.flush();}
		void pln(long x) {w.println(x);w.flush();}
		void pln(String x) {w.println(x);w.flush();}
		void pln(char x) {w.println(x);w.flush();}
		void pln(StringBuilder x) {w.println(x);w.flush();}
		void pln(BigInteger x) {w.println(x);w.flush();}
		void p(int x) {w.print(x);w.flush();}
		void p(long x) {w.print(x);w.flush();}
		void p(String x) {w.print(x);w.flush();}
		void p(char x) {w.print(x);w.flush();}
		void p(StringBuilder x) {w.print(x);w.flush();}
		void p(BigInteger x) {w.print(x);w.flush();}
		void p(double x) {w.print(x);w.flush();}
		void p(boolean x) {w.print(x);w.flush();}
	}
} import java.io.*; io.* java import java.math.*; math.* java import java.util.*; util.* java public class Main {  
 
	public static void main(String[] args) { 
		FastScanner I = new FastScanner(); //Input
		OutPut O = new OutPut(); //Output
		int Z = 0;
		int ONE = 0;
		String S = I.next();
		for (int i = 0; i < S.length(); i++) {
			if (S.charAt(i)=='0') Z++;
			else ONE++;
		}
		O.pln(Math.min(ONE, Z)*2);
	}
	public static ArrayList<String> perms(int N, int upper){
		if (N==1) {
			ArrayList<String> ret = new ArrayList<String>();
			for (int i = 1; i<=upper; i++) ret.add(Integer.toString(i)+" ");
			return ret;
		}
		ArrayList<String> prev = perms(N-1,upper);
		ArrayList<String> ret = new ArrayList<String>();
		for (int i = 0; i < prev.size(); i++) {
			boolean[] vis = new boolean[upper+1];
			String cur = prev.get(i);
			String[] parts = cur.split(" ");
			for (int j = 0; j < parts.length; j++) {
				vis[Integer.parseInt(parts[j])]=true;
			}
			for (int j = 1; j <= upper; j++) {
				if (!vis[j]) {
					String curans = cur;
					curans+=Integer.toString(j)+" ";
					ret.add(curans);
				}
			}
		}
		return ret;
	}
	public static long ceil(long num, long den) {long ans = num/den; if (num%den!=0) 
	ans++; return ans;}
	public static long GCD(long a, long b) {
		if (a==0||b==0) return Math.max(a,b);
		return GCD(Math.min(a, b),Math.max(a, b)%Math.min(a, b));
	}
	public static long FastExp(long base, long exp, long mod) {
		long ans=1;
		while (exp>0) {
			if (exp%2==1) ans*=base;
			exp/=2;
			base*=base;
			base%=mod;
			ans%=mod;
		}
		return ans;
	}
	public static long ModInv(long num,long mod) {return FastExp(num,mod-2,mod);}
	public static int pop(long x) { //Returns number of bits within a number
		int cnt = 0;
		while (x>0) {
			if (x%2==1) cnt++;
			x/=2;
		}
		return cnt;
	}
	static class FastScanner {
		BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st=new StringTokenizer("");
		String next() {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		}
		int nextInt() {return Integer.parseInt(next());}
		long nextLong() {return Long.parseLong(next());};
		double nextDouble() {return Double.parseDouble(next());}
	}
	static class OutPut{
		PrintWriter w = new PrintWriter(System.out);
		void pln(double x) {w.println(x);w.flush();}
		void pln(boolean x) {w.println(x);w.flush();}
		void pln(int x) {w.println(x);w.flush();}
		void pln(long x) {w.println(x);w.flush();}
		void pln(String x) {w.println(x);w.flush();}
		void pln(char x) {w.println(x);w.flush();}
		void pln(StringBuilder x) {w.println(x);w.flush();}
		void pln(BigInteger x) {w.println(x);w.flush();}
		void p(int x) {w.print(x);w.flush();}
		void p(long x) {w.print(x);w.flush();}
		void p(String x) {w.print(x);w.flush();}
		void p(char x) {w.print(x);w.flush();}
		void p(StringBuilder x) {w.print(x);w.flush();}
		void p(BigInteger x) {w.print(x);w.flush();}
		void p(double x) {w.print(x);w.flush();}
		void p(boolean x) {w.print(x);w.flush();}
	}
} Main public static void main(String[] args) { 
		FastScanner I = new FastScanner(); //Input
		OutPut O = new OutPut(); //Output
		int Z = 0;
		int ONE = 0;
		String S = I.next();
		for (int i = 0; i < S.length(); i++) {
			if (S.charAt(i)=='0') Z++;
			else ONE++;
		}
		O.pln(Math.min(ONE, Z)*2);
	} main { 
		FastScanner I = new FastScanner(); //Input
		OutPut O = new OutPut(); //Output
		int Z = 0;
		int ONE = 0;
		String S = I.next();
		for (int i = 0; i < S.length(); i++) {
			if (S.charAt(i)=='0') Z++;
			else ONE++;
		}
		O.pln(Math.min(ONE, Z)*2);
	} FastScanner I = new FastScanner(); I new FastScanner() OutPut O = new OutPut(); O new OutPut() int Z = 0; Z 0 int ONE = 0; ONE 0 String S = I.next(); S I.next() I.next I for (int i = 0; i < S.length(); i++) {
			if (S.charAt(i)=='0') Z++;
			else ONE++;
		} int i = 0; int i = 0; i 0 i < S.length() i S.length() S.length S i++ i++ i {
			if (S.charAt(i)=='0') Z++;
			else ONE++;
		} {
			if (S.charAt(i)=='0') Z++;
			else ONE++;
		} if (S.charAt(i)=='0') Z++;
			else ONE++; S.charAt(i)=='0' S.charAt(i) S.charAt S i '0' Z++ Z ONE++ ONE O.pln(Math.min(ONE, Z)*2) O.pln O Math.min(ONE, Z)*2 Math.min(ONE, Z) Math.min Math ONE Z 2 String[] args args public static ArrayList<String> perms(int N, int upper){
		if (N==1) {
			ArrayList<String> ret = new ArrayList<String>();
			for (int i = 1; i<=upper; i++) ret.add(Integer.toString(i)+" ");
			return ret;
		}
		ArrayList<String> prev = perms(N-1,upper);
		ArrayList<String> ret = new ArrayList<String>();
		for (int i = 0; i < prev.size(); i++) {
			boolean[] vis = new boolean[upper+1];
			String cur = prev.get(i);
			String[] parts = cur.split(" ");
			for (int j = 0; j < parts.length; j++) {
				vis[Integer.parseInt(parts[j])]=true;
			}
			for (int j = 1; j <= upper; j++) {
				if (!vis[j]) {
					String curans = cur;
					curans+=Integer.toString(j)+" ";
					ret.add(curans);
				}
			}
		}
		return ret;
	} perms {
		if (N==1) {
			ArrayList<String> ret = new ArrayList<String>();
			for (int i = 1; i<=upper; i++) ret.add(Integer.toString(i)+" ");
			return ret;
		}
		ArrayList<String> prev = perms(N-1,upper);
		ArrayList<String> ret = new ArrayList<String>();
		for (int i = 0; i < prev.size(); i++) {
			boolean[] vis = new boolean[upper+1];
			String cur = prev.get(i);
			String[] parts = cur.split(" ");
			for (int j = 0; j < parts.length; j++) {
				vis[Integer.parseInt(parts[j])]=true;
			}
			for (int j = 1; j <= upper; j++) {
				if (!vis[j]) {
					String curans = cur;
					curans+=Integer.toString(j)+" ";
					ret.add(curans);
				}
			}
		}
		return ret;
	} if (N==1) {
			ArrayList<String> ret = new ArrayList<String>();
			for (int i = 1; i<=upper; i++) ret.add(Integer.toString(i)+" ");
			return ret;
		} N==1 N 1 {
			ArrayList<String> ret = new ArrayList<String>();
			for (int i = 1; i<=upper; i++) ret.add(Integer.toString(i)+" ");
			return ret;
		} ArrayList<String> ret = new ArrayList<String>(); ret new ArrayList<String>() for (int i = 1; i<=upper; i++) ret.add(Integer.toString(i)+" "); int i = 1; int i = 1; i 1 i<=upper i upper i++ i++ i ret.add(Integer.toString(i)+" "); ret.add(Integer.toString(i)+" ") ret.add ret Integer.toString(i)+" " Integer.toString(i) Integer.toString Integer i " " return ret; ret ArrayList<String> prev = perms(N-1,upper); prev perms(N-1,upper) perms N-1 N 1 upper ArrayList<String> ret = new ArrayList<String>(); ret new ArrayList<String>() for (int i = 0; i < prev.size(); i++) {
			boolean[] vis = new boolean[upper+1];
			String cur = prev.get(i);
			String[] parts = cur.split(" ");
			for (int j = 0; j < parts.length; j++) {
				vis[Integer.parseInt(parts[j])]=true;
			}
			for (int j = 1; j <= upper; j++) {
				if (!vis[j]) {
					String curans = cur;
					curans+=Integer.toString(j)+" ";
					ret.add(curans);
				}
			}
		} int i = 0; int i = 0; i 0 i < prev.size() i prev.size() prev.size prev i++ i++ i {
			boolean[] vis = new boolean[upper+1];
			String cur = prev.get(i);
			String[] parts = cur.split(" ");
			for (int j = 0; j < parts.length; j++) {
				vis[Integer.parseInt(parts[j])]=true;
			}
			for (int j = 1; j <= upper; j++) {
				if (!vis[j]) {
					String curans = cur;
					curans+=Integer.toString(j)+" ";
					ret.add(curans);
				}
			}
		} {
			boolean[] vis = new boolean[upper+1];
			String cur = prev.get(i);
			String[] parts = cur.split(" ");
			for (int j = 0; j < parts.length; j++) {
				vis[Integer.parseInt(parts[j])]=true;
			}
			for (int j = 1; j <= upper; j++) {
				if (!vis[j]) {
					String curans = cur;
					curans+=Integer.toString(j)+" ";
					ret.add(curans);
				}
			}
		} boolean[] vis = new boolean[upper+1]; vis new boolean[upper+1] upper+1 upper 1 String cur = prev.get(i); cur prev.get(i) prev.get prev i String[] parts = cur.split(" "); parts cur.split(" ") cur.split cur " " for (int j = 0; j < parts.length; j++) {
				vis[Integer.parseInt(parts[j])]=true;
			} int j = 0; int j = 0; j 0 j < parts.length j parts.length parts parts.length j++ j++ j {
				vis[Integer.parseInt(parts[j])]=true;
			} {
				vis[Integer.parseInt(parts[j])]=true;
			} vis[Integer.parseInt(parts[j])]=true vis[Integer.parseInt(parts[j])] vis Integer.parseInt(parts[j]) Integer.parseInt Integer parts[j] parts j true for (int j = 1; j <= upper; j++) {
				if (!vis[j]) {
					String curans = cur;
					curans+=Integer.toString(j)+" ";
					ret.add(curans);
				}
			} int j = 1; int j = 1; j 1 j <= upper j upper j++ j++ j {
				if (!vis[j]) {
					String curans = cur;
					curans+=Integer.toString(j)+" ";
					ret.add(curans);
				}
			} {
				if (!vis[j]) {
					String curans = cur;
					curans+=Integer.toString(j)+" ";
					ret.add(curans);
				}
			} if (!vis[j]) {
					String curans = cur;
					curans+=Integer.toString(j)+" ";
					ret.add(curans);
				} !vis[j] vis[j] vis j {
					String curans = cur;
					curans+=Integer.toString(j)+" ";
					ret.add(curans);
				} String curans = cur; curans cur curans+=Integer.toString(j)+" " curans Integer.toString(j)+" " Integer.toString(j) Integer.toString Integer j " " ret.add(curans) ret.add ret curans return ret; ret int N N int upper upper public static long ceil(long num, long den) {long ans = num/den; if (num%den!=0) 
	ans++; return ans;} ceil {long ans = num/den; if (num%den!=0) 
	ans++; return ans;} long ans = num/den; ans num/den num den if (num%den!=0) 
	ans++; num%den!=0 num%den num den 0 ans++ ans return ans; ans long num num long den den public static long GCD(long a, long b) {
		if (a==0||b==0) return Math.max(a,b);
		return GCD(Math.min(a, b),Math.max(a, b)%Math.min(a, b));
	} GCD {
		if (a==0||b==0) return Math.max(a,b);
		return GCD(Math.min(a, b),Math.max(a, b)%Math.min(a, b));
	} if (a==0||b==0) return Math.max(a,b); a==0||b==0 a==0 a 0 b==0 b 0 return Math.max(a,b); Math.max(a,b) Math.max Math a b return GCD(Math.min(a, b),Math.max(a, b)%Math.min(a, b)); GCD(Math.min(a, b),Math.max(a, b)%Math.min(a, b)) GCD Math.min(a, b) Math.min Math a b Math.max(a, b)%Math.min(a, b) Math.max(a, b) Math.max Math a b Math.min(a, b) Math.min Math a b long a a long b b public static long FastExp(long base, long exp, long mod) {
		long ans=1;
		while (exp>0) {
			if (exp%2==1) ans*=base;
			exp/=2;
			base*=base;
			base%=mod;
			ans%=mod;
		}
		return ans;
	} FastExp {
		long ans=1;
		while (exp>0) {
			if (exp%2==1) ans*=base;
			exp/=2;
			base*=base;
			base%=mod;
			ans%=mod;
		}
		return ans;
	} long ans=1; ans 1 while (exp>0) {
			if (exp%2==1) ans*=base;
			exp/=2;
			base*=base;
			base%=mod;
			ans%=mod;
		} exp>0 exp 0 {
			if (exp%2==1) ans*=base;
			exp/=2;
			base*=base;
			base%=mod;
			ans%=mod;
		} if (exp%2==1) ans*=base; exp%2==1 exp%2 exp 2 1 ans*=base ans base exp/=2 exp 2 base*=base base base base%=mod base mod ans%=mod ans mod return ans; ans long base base long exp exp long mod mod public static long ModInv(long num,long mod) {return FastExp(num,mod-2,mod);} ModInv {return FastExp(num,mod-2,mod);} return FastExp(num,mod-2,mod); FastExp(num,mod-2,mod) FastExp num mod-2 mod 2 mod long num num long mod mod public static int pop(long x) { //Returns number of bits within a number
		int cnt = 0;
		while (x>0) {
			if (x%2==1) cnt++;
			x/=2;
		}
		return cnt;
	} pop { //Returns number of bits within a number
		int cnt = 0;
		while (x>0) {
			if (x%2==1) cnt++;
			x/=2;
		}
		return cnt;
	} int cnt = 0; cnt 0 while (x>0) {
			if (x%2==1) cnt++;
			x/=2;
		} x>0 x 0 {
			if (x%2==1) cnt++;
			x/=2;
		} if (x%2==1) cnt++; x%2==1 x%2 x 2 1 cnt++ cnt x/=2 x 2 return cnt; cnt long x x static class FastScanner {
		BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st=new StringTokenizer("");
		String next() {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		}
		int nextInt() {return Integer.parseInt(next());}
		long nextLong() {return Long.parseLong(next());};
		double nextDouble() {return Double.parseDouble(next());}
	} FastScanner BufferedReader br=new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) StringTokenizer st=new StringTokenizer(""); st new StringTokenizer("") String next() {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		} next {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		} while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				} !st.hasMoreTokens() st.hasMoreTokens() st.hasMoreTokens st try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				} catch (IOException e) {
					e.printStackTrace();
				} IOException e {
					e.printStackTrace();
				} e.printStackTrace() e.printStackTrace e {
					st=new StringTokenizer(br.readLine());
				} st=new StringTokenizer(br.readLine()) st new StringTokenizer(br.readLine()) return st.nextToken(); st.nextToken() st.nextToken st int nextInt() {return Integer.parseInt(next());} nextInt {return Integer.parseInt(next());} return Integer.parseInt(next()); Integer.parseInt(next()) Integer.parseInt Integer next() next long nextLong() {return Long.parseLong(next());} nextLong {return Long.parseLong(next());} return Long.parseLong(next()); Long.parseLong(next()) Long.parseLong Long next() next double nextDouble() {return Double.parseDouble(next());} nextDouble {return Double.parseDouble(next());} return Double.parseDouble(next()); Double.parseDouble(next()) Double.parseDouble Double next() next static class OutPut{
		PrintWriter w = new PrintWriter(System.out);
		void pln(double x) {w.println(x);w.flush();}
		void pln(boolean x) {w.println(x);w.flush();}
		void pln(int x) {w.println(x);w.flush();}
		void pln(long x) {w.println(x);w.flush();}
		void pln(String x) {w.println(x);w.flush();}
		void pln(char x) {w.println(x);w.flush();}
		void pln(StringBuilder x) {w.println(x);w.flush();}
		void pln(BigInteger x) {w.println(x);w.flush();}
		void p(int x) {w.print(x);w.flush();}
		void p(long x) {w.print(x);w.flush();}
		void p(String x) {w.print(x);w.flush();}
		void p(char x) {w.print(x);w.flush();}
		void p(StringBuilder x) {w.print(x);w.flush();}
		void p(BigInteger x) {w.print(x);w.flush();}
		void p(double x) {w.print(x);w.flush();}
		void p(boolean x) {w.print(x);w.flush();}
	} OutPut PrintWriter w = new PrintWriter(System.out); w new PrintWriter(System.out) void pln(double x) {w.println(x);w.flush();} pln {w.println(x);w.flush();} w.println(x) w.println w x w.flush() w.flush w double x x void pln(boolean x) {w.println(x);w.flush();} pln {w.println(x);w.flush();} w.println(x) w.println w x w.flush() w.flush w boolean x x void pln(int x) {w.println(x);w.flush();} pln {w.println(x);w.flush();} w.println(x) w.println w x w.flush() w.flush w int x x void pln(long x) {w.println(x);w.flush();} pln {w.println(x);w.flush();} w.println(x) w.println w x w.flush() w.flush w long x x void pln(String x) {w.println(x);w.flush();} pln {w.println(x);w.flush();} w.println(x) w.println w x w.flush() w.flush w String x x void pln(char x) {w.println(x);w.flush();} pln {w.println(x);w.flush();} w.println(x) w.println w x w.flush() w.flush w char x x void pln(StringBuilder x) {w.println(x);w.flush();} pln {w.println(x);w.flush();} w.println(x) w.println w x w.flush() w.flush w StringBuilder x x void pln(BigInteger x) {w.println(x);w.flush();} pln {w.println(x);w.flush();} w.println(x) w.println w x w.flush() w.flush w BigInteger x x void p(int x) {w.print(x);w.flush();} p {w.print(x);w.flush();} w.print(x) w.print w x w.flush() w.flush w int x x void p(long x) {w.print(x);w.flush();} p {w.print(x);w.flush();} w.print(x) w.print w x w.flush() w.flush w long x x void p(String x) {w.print(x);w.flush();} p {w.print(x);w.flush();} w.print(x) w.print w x w.flush() w.flush w String x x void p(char x) {w.print(x);w.flush();} p {w.print(x);w.flush();} w.print(x) w.print w x w.flush() w.flush w char x x void p(StringBuilder x) {w.print(x);w.flush();} p {w.print(x);w.flush();} w.print(x) w.print w x w.flush() w.flush w StringBuilder x x void p(BigInteger x) {w.print(x);w.flush();} p {w.print(x);w.flush();} w.print(x) w.print w x w.flush() w.flush w BigInteger x x void p(double x) {w.print(x);w.flush();} p {w.print(x);w.flush();} w.print(x) w.print w x w.flush() w.flush w double x x void p(boolean x) {w.print(x);w.flush();} p {w.print(x);w.flush();} w.print(x) w.print w x w.flush() w.flush w boolean x x public class Main {  
 
	public static void main(String[] args) { 
		FastScanner I = new FastScanner(); //Input
		OutPut O = new OutPut(); //Output
		int Z = 0;
		int ONE = 0;
		String S = I.next();
		for (int i = 0; i < S.length(); i++) {
			if (S.charAt(i)=='0') Z++;
			else ONE++;
		}
		O.pln(Math.min(ONE, Z)*2);
	}
	public static ArrayList<String> perms(int N, int upper){
		if (N==1) {
			ArrayList<String> ret = new ArrayList<String>();
			for (int i = 1; i<=upper; i++) ret.add(Integer.toString(i)+" ");
			return ret;
		}
		ArrayList<String> prev = perms(N-1,upper);
		ArrayList<String> ret = new ArrayList<String>();
		for (int i = 0; i < prev.size(); i++) {
			boolean[] vis = new boolean[upper+1];
			String cur = prev.get(i);
			String[] parts = cur.split(" ");
			for (int j = 0; j < parts.length; j++) {
				vis[Integer.parseInt(parts[j])]=true;
			}
			for (int j = 1; j <= upper; j++) {
				if (!vis[j]) {
					String curans = cur;
					curans+=Integer.toString(j)+" ";
					ret.add(curans);
				}
			}
		}
		return ret;
	}
	public static long ceil(long num, long den) {long ans = num/den; if (num%den!=0) 
	ans++; return ans;}
	public static long GCD(long a, long b) {
		if (a==0||b==0) return Math.max(a,b);
		return GCD(Math.min(a, b),Math.max(a, b)%Math.min(a, b));
	}
	public static long FastExp(long base, long exp, long mod) {
		long ans=1;
		while (exp>0) {
			if (exp%2==1) ans*=base;
			exp/=2;
			base*=base;
			base%=mod;
			ans%=mod;
		}
		return ans;
	}
	public static long ModInv(long num,long mod) {return FastExp(num,mod-2,mod);}
	public static int pop(long x) { //Returns number of bits within a number
		int cnt = 0;
		while (x>0) {
			if (x%2==1) cnt++;
			x/=2;
		}
		return cnt;
	}
	static class FastScanner {
		BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st=new StringTokenizer("");
		String next() {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		}
		int nextInt() {return Integer.parseInt(next());}
		long nextLong() {return Long.parseLong(next());};
		double nextDouble() {return Double.parseDouble(next());}
	}
	static class OutPut{
		PrintWriter w = new PrintWriter(System.out);
		void pln(double x) {w.println(x);w.flush();}
		void pln(boolean x) {w.println(x);w.flush();}
		void pln(int x) {w.println(x);w.flush();}
		void pln(long x) {w.println(x);w.flush();}
		void pln(String x) {w.println(x);w.flush();}
		void pln(char x) {w.println(x);w.flush();}
		void pln(StringBuilder x) {w.println(x);w.flush();}
		void pln(BigInteger x) {w.println(x);w.flush();}
		void p(int x) {w.print(x);w.flush();}
		void p(long x) {w.print(x);w.flush();}
		void p(String x) {w.print(x);w.flush();}
		void p(char x) {w.print(x);w.flush();}
		void p(StringBuilder x) {w.print(x);w.flush();}
		void p(BigInteger x) {w.print(x);w.flush();}
		void p(double x) {w.print(x);w.flush();}
		void p(boolean x) {w.print(x);w.flush();}
	}
} public class Main {  
 
	public static void main(String[] args) { 
		FastScanner I = new FastScanner(); //Input
		OutPut O = new OutPut(); //Output
		int Z = 0;
		int ONE = 0;
		String S = I.next();
		for (int i = 0; i < S.length(); i++) {
			if (S.charAt(i)=='0') Z++;
			else ONE++;
		}
		O.pln(Math.min(ONE, Z)*2);
	}
	public static ArrayList<String> perms(int N, int upper){
		if (N==1) {
			ArrayList<String> ret = new ArrayList<String>();
			for (int i = 1; i<=upper; i++) ret.add(Integer.toString(i)+" ");
			return ret;
		}
		ArrayList<String> prev = perms(N-1,upper);
		ArrayList<String> ret = new ArrayList<String>();
		for (int i = 0; i < prev.size(); i++) {
			boolean[] vis = new boolean[upper+1];
			String cur = prev.get(i);
			String[] parts = cur.split(" ");
			for (int j = 0; j < parts.length; j++) {
				vis[Integer.parseInt(parts[j])]=true;
			}
			for (int j = 1; j <= upper; j++) {
				if (!vis[j]) {
					String curans = cur;
					curans+=Integer.toString(j)+" ";
					ret.add(curans);
				}
			}
		}
		return ret;
	}
	public static long ceil(long num, long den) {long ans = num/den; if (num%den!=0) 
	ans++; return ans;}
	public static long GCD(long a, long b) {
		if (a==0||b==0) return Math.max(a,b);
		return GCD(Math.min(a, b),Math.max(a, b)%Math.min(a, b));
	}
	public static long FastExp(long base, long exp, long mod) {
		long ans=1;
		while (exp>0) {
			if (exp%2==1) ans*=base;
			exp/=2;
			base*=base;
			base%=mod;
			ans%=mod;
		}
		return ans;
	}
	public static long ModInv(long num,long mod) {return FastExp(num,mod-2,mod);}
	public static int pop(long x) { //Returns number of bits within a number
		int cnt = 0;
		while (x>0) {
			if (x%2==1) cnt++;
			x/=2;
		}
		return cnt;
	}
	static class FastScanner {
		BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st=new StringTokenizer("");
		String next() {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		}
		int nextInt() {return Integer.parseInt(next());}
		long nextLong() {return Long.parseLong(next());};
		double nextDouble() {return Double.parseDouble(next());}
	}
	static class OutPut{
		PrintWriter w = new PrintWriter(System.out);
		void pln(double x) {w.println(x);w.flush();}
		void pln(boolean x) {w.println(x);w.flush();}
		void pln(int x) {w.println(x);w.flush();}
		void pln(long x) {w.println(x);w.flush();}
		void pln(String x) {w.println(x);w.flush();}
		void pln(char x) {w.println(x);w.flush();}
		void pln(StringBuilder x) {w.println(x);w.flush();}
		void pln(BigInteger x) {w.println(x);w.flush();}
		void p(int x) {w.print(x);w.flush();}
		void p(long x) {w.print(x);w.flush();}
		void p(String x) {w.print(x);w.flush();}
		void p(char x) {w.print(x);w.flush();}
		void p(StringBuilder x) {w.print(x);w.flush();}
		void p(BigInteger x) {w.print(x);w.flush();}
		void p(double x) {w.print(x);w.flush();}
		void p(boolean x) {w.print(x);w.flush();}
	}
} Main

import java.io.*;
import java.math.*;
import java.util.*;
public class Main {  
 
	public static void main(String[] args) { 
		FastScanner I = new FastScanner(); //Input
		OutPut O = new OutPut(); //Output
		int Z = 0;
		int ONE = 0;
		String S = I.next();
		for (int i = 0; i < S.length(); i++) {
			if (S.charAt(i)=='0') Z++;
			else ONE++;
		}
		O.pln(Math.min(ONE, Z)*2);
	}
	public static ArrayList<String> perms(int N, int upper){
		if (N==1) {
			ArrayList<String> ret = new ArrayList<String>();
			for (int i = 1; i<=upper; i++) ret.add(Integer.toString(i)+" ");
			return ret;
		}
		ArrayList<String> prev = perms(N-1,upper);
		ArrayList<String> ret = new ArrayList<String>();
		for (int i = 0; i < prev.size(); i++) {
			boolean[] vis = new boolean[upper+1];
			String cur = prev.get(i);
			String[] parts = cur.split(" ");
			for (int j = 0; j < parts.length; j++) {
				vis[Integer.parseInt(parts[j])]=true;
			}
			for (int j = 1; j <= upper; j++) {
				if (!vis[j]) {
					String curans = cur;
					curans+=Integer.toString(j)+" ";
					ret.add(curans);
				}
			}
		}
		return ret;
	}
	public static long ceil(long num, long den) {long ans = num/den; if (num%den!=0) 
	ans++; return ans;}
	public static long GCD(long a, long b) {
		if (a==0||b==0) return Math.max(a,b);
		return GCD(Math.min(a, b),Math.max(a, b)%Math.min(a, b));
	}
	public static long FastExp(long base, long exp, long mod) {
		long ans=1;
		while (exp>0) {
			if (exp%2==1) ans*=base;
			exp/=2;
			base*=base;
			base%=mod;
			ans%=mod;
		}
		return ans;
	}
	public static long ModInv(long num,long mod) {return FastExp(num,mod-2,mod);}
	public static int pop(long x) { //Returns number of bits within a number
		int cnt = 0;
		while (x>0) {
			if (x%2==1) cnt++;
			x/=2;
		}
		return cnt;
	}
	static class FastScanner {
		BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st=new StringTokenizer("");
		String next() {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		}
		int nextInt() {return Integer.parseInt(next());}
		long nextLong() {return Long.parseLong(next());};
		double nextDouble() {return Double.parseDouble(next());}
	}
	static class OutPut{
		PrintWriter w = new PrintWriter(System.out);
		void pln(double x) {w.println(x);w.flush();}
		void pln(boolean x) {w.println(x);w.flush();}
		void pln(int x) {w.println(x);w.flush();}
		void pln(long x) {w.println(x);w.flush();}
		void pln(String x) {w.println(x);w.flush();}
		void pln(char x) {w.println(x);w.flush();}
		void pln(StringBuilder x) {w.println(x);w.flush();}
		void pln(BigInteger x) {w.println(x);w.flush();}
		void p(int x) {w.print(x);w.flush();}
		void p(long x) {w.print(x);w.flush();}
		void p(String x) {w.print(x);w.flush();}
		void p(char x) {w.print(x);w.flush();}
		void p(StringBuilder x) {w.print(x);w.flush();}
		void p(BigInteger x) {w.print(x);w.flush();}
		void p(double x) {w.print(x);w.flush();}
		void p(boolean x) {w.print(x);w.flush();}
	}
}
