#include #define ll long long #define INF 1000000005 #define MOD 1000000007 #define EPS 1e-10 #define rep(i,n) for(int i=0;i<(int)n;++i) #define each(a, b) for(auto (a): (b)) #define all(v) (v).begin(),(v).end() #define fi first #define se second #define pb push_back #define show(x) cout <<#x<<" = "<<(x)<P; const int MAX_N = 100005; int main() { int n; cin >> n; vector pl,mn,ze; rep(i,2*n){ int a; cin >> a; if(a > 0){ pl.pb(a); }else if(a < 0){ mn.pb(a); }else{ ze.pb(a); } } sort(all(pl)); sort(all(mn)); int n1,n2; n1 = pl.size()-1; n2 = 0; int ans1 = 0; while(n1 >= 0 && n2 < mn.size()){ if(pl[n1]+mn[n2] < 0){ n1--; n2++; ans1++; }else{ n1--; } } int cnt = (int)mn.size() - ans1; if(cnt%2){ if(ze.size() > 0){ ans1 += (cnt+1)/2; }else{ ans1 += cnt/2; } }else{ ans1 += cnt/2; } n1 = 0; n2 = (int)mn.size()-1; int ans2 = 0; while(n1 < pl.size() && n2 >= 0){ if(pl[n1] > -mn[n2]){ n2--; }else if(pl[n1] < -mn[n2]){ n1++; }else{ ans2++; n1++; n2--; } } ans2 += (int)ze.size() / 2; n1 = (int)pl.size()-1; n2 = 0; int ans3 = 0; while(n1 >= 0 && n2 < (int)mn.size()){ if(pl[n1]+mn[n2] > 0){ n1--; n2++; ans3++; }else{ n2++; } } cnt = (int)pl.size() - ans3; if(cnt%2){ if(ze.size() > 0){ ans3 += (cnt+1)/2; }else{ ans3 += cnt/2; } }else{ ans3 += cnt/2; } cout << ans1 << " " << ans3 << " " << ans2 << endl; return 0; }