#include #define rep(i,n) for(int i=0; i< (n); i++) using namespace std; typedef long long ll; typedef pair P; const int mod = 998244353; const int inf = (1<<30); const ll INF = (1ull<<62); int main(){ int n; cin>>n; vector a(n); rep(i,n) cin>>a[i]; sort(a.begin(),a.end()); if(n >= 3 && n%2 == 1) cout<<1<