/* Как-то средненько */ import java.io.*; import java.util.*; public class Solution { public static void main(String[] args) throws Exception { //напишите тут ваш код int a=toInt(read()); int b=toInt(read()); int c=toInt(read()); print(m(a,b,c)); } public static void print(Object o){ System.out.println(o); } public static String read() throws Exception { return new BufferedReader(new InputStreamReader(System.in)).readLine(); } public static int toInt(String s){ return Integer.parseInt(s); } public static int m(int a,int b, int c){ if(a==b){ return a; }else if(b==c){ return b; }else if(a==c){ return a; }else{ return xor(a,b,c); } } public static int max(int a,int b){ if(a>b){ return a; }else{ return b; } } public static int min(int a,int b){ if(a<b){ return a; }else{ return b; } } public static int xor(int a,int b,int c){ int x=min(min(a,b),c); int y=max(max(a,b),c); if(a!=x&&a!=y){ return a; }else if(b!=x&&b!=y){ return b; }else{ return c; } } }