using System; using System.Collections.Generic; using System.Linq; class P { class PriorityQueue { private readonly List heap; private readonly Comparison compare; private int size; public PriorityQueue() : this(Comparer.Default) { } public PriorityQueue(IComparer comparer) : this(16, comparer.Compare) { } public PriorityQueue(Comparison comparison) : this(16, comparison) { } public PriorityQueue(int capacity, Comparison comparison) { this.heap = new List(capacity); this.compare = comparison; } public void Enqueue(T item) { this.heap.Add(item); var i = size++; while (i > 0) { var p = (i - 1) >> 1; if (compare(this.heap[p], item) <= 0) break; this.heap[i] = heap[p]; i = p; } this.heap[i] = item; } public T Dequeue() { var ret = this.heap[0]; var x = this.heap[--size]; var i = 0; while ((i << 1) + 1 < size) { var a = (i << 1) + 1; var b = (i << 1) + 2; if (b < size && compare(heap[b], heap[a]) < 0) a = b; if (compare(heap[a], x) >= 0) break; heap[i] = heap[a]; i = a; } heap[i] = x; heap.RemoveAt(size); return ret; } public T Peek() { return heap[0]; } public int Count { get { return size; } } public bool Any() { return size > 0; } } static void Solve() { while (2 < W.Count) { int l1 = W.Dequeue(); int l2 = W.Dequeue(); W.Enqueue(l1 + l2); } } static int N; static PriorityQueue W = new PriorityQueue(); static void Main(string[] _) { N = int.Parse(Console.ReadLine()); _ = Console.ReadLine().Split(' '); for (int i = 0; i < N; i++) { W.Enqueue(int.Parse(_[i])); } Solve(); Console.WriteLine(W.Dequeue() == W.Dequeue() ? "possible" : "impossible"); } }