1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#include <bits/stdc++.h>
using namespace std;
const int maxn = 3e5;
typedef long long ll;
typedef pair<int, int> Pii;
typedef vector<Pii> vpii;
typedef vector<int> vi;
typedef vector<ll> vll;
#define pb push_back
#define fst first
#define snd second
int n;
int main()
{
	scanf("%d", &n);
	int jed = 0;
	for(int i =0 ; i < n; ++i)
	{
		int d;
		scanf("%d", &d);
		if(d == 1)
			++jed;
	}
	jed = min(jed, 2);
	int ans = 2 - jed;
	printf("%d\n2\n1 2\n", ans);
}