#include <iostream>

using namespace std;

int main()
{
    int n,a;
    cin>>n;

    cout<<n<<endl;
    for(int i=0;i<n;i++){
        cin>>a;
        if(a>=0)
            cout<<1<<" ";
        else
            cout<<2<<" ";

    }
    return 0;
}