using System; using System.Collections.Generic; using System.Linq; using System.IO; using System.Text; using static System.Console; using static System.Math; namespace CP { class Atria { static void Main(string[] args) { int n = int.Parse(ReadLine()); try { var ls = new List(); for (int i = 0; i < n; i++) { ls.Add(long.Parse(ReadLine())); } var hoge = new List(); hoge.Add(ls[0] + ls[1]); hoge.Add(ls[2] + ls[1]); hoge.Add(ls[0] + ls[2]); hoge.Sort(); if (hoge[0] == hoge[1]) { WriteLine(hoge[1]); } else if (hoge[1] == hoge[2]) { WriteLine(hoge[0]); } else { WriteLine(hoge[1]); } } catch (Exception) { WriteLine('"' + "assert" + '"'); } } } }