#include using namespace std; pair< int, int > solve(vector< int > A) { sort(begin(A), end(A)); int latte = 0, malta = 0; set< int > mp; for(int i = 0; i < A.size(); i++) { if(mp.count(-A[i])) { ++malta; mp.erase(-A[i]); } mp.emplace(A[i]); } int ptr = 0; for(int i = A.size() - 1; i >= 0; i--) { while(ptr < A.size() && A[ptr] + A[i] <= 0) ++ptr; if(ptr >= i) break; ++ptr; ++latte; } return {latte, malta}; } int main() { int N; cin >> N; N *= 2; vector< int > A(N); for(int i = 0; i < N; i++) cin >> A[i]; for(int i = 0; i < N; i++) A[i] *= -1; cout << solve(A).first << " "; for(int i = 0; i < N; i++) A[i] *= -1; cout << solve(A).first << " " << solve(A).second << endl; }