1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
#include <iostream>
#include <math.h>
using namespace std;

int main() {
	int n;
	cin>>n;
	long long int sum = 0;
	while(cin>>n) {
		sum += pow(2, n);
	}
	cout<<(int)log2(sum);
	return 0;
}