Problem: Fox Ciel is participating in a party in Prime Kingdom. There are n foxes there (include Fox Ciel). The i-th fox is ai years old.

They will have dinner around some round tables. You want to distribute foxes such that:

  1. Each fox is sitting at some table. 
  2. Each table has at least 3 foxes sitting around it. 
  3. The sum of ages of any two adjacent foxes around each table should be a prime number. 



If k foxes f1, f2, ..., fk are sitting around table in clockwise order, then for 1 ≤ i ≤ k - 1: fi and fi + 1 are adjacent, and f1 and fk are also adjacent.

If it is possible to distribute the foxes in the desired manner, find out a way to do that.

Input

The first line contains single integer n (3 ≤ n ≤ 200): the number of foxes in this party. 

The second line contains n integers ai (2 ≤ ai ≤ 104).

Output

If it is impossible to do this, output "Impossible".

Otherwise, in the first line output an integer m (<image>): the number of tables.

Then output m lines, each line should start with an integer k -=– the number of foxes around that table, and then k numbers — indices of fox sitting around that table in clockwise order.

If there are several possible arrangements, output any of them.

Examples

Input

4
3 4 8 9


Output

1
4 1 2 4 3


Input

5
2 2 2 2 2


Output

Impossible


Input

12
2 3 4 5 6 7 8 9 10 11 12 13


Output

1
12 1 2 3 6 5 12 9 8 7 10 11 4


Input

24
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25


Output

3
6 1 2 3 6 5 4
10 7 8 9 12 15 14 13 16 11 10
8 17 18 23 22 19 20 21 24

Note

In example 1, they can sit around one table, their ages are: 3-8-9-4, adjacent sums are: 11, 17, 13 and 7, all those integers are primes.

In example 2, it is not possible: the sum of 2+2 = 4 is not a prime number.

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
const int N = 205;
const int M = 1e5;
const int inf = 1e9;
int n, v[N], pr[M], a[N], b[N], A, B, start, finish, ptr[N], d[N], q[N * N], qh,
    qt, used[N];
vector<int> gg[N];
struct edge {
  int from, to, cap, flow;
};
vector<int> g[N];
vector<edge> e;
void add_edge(int from, int to, int cap) {
  g[from].push_back(e.size());
  e.push_back({from, to, cap, 0});
  g[to].push_back(e.size());
  e.push_back({to, from, 0, 0});
}
bool bfs() {
  for (int i = 0; i <= finish; i++) d[i] = -1;
  d[start] = 0;
  qh = qt = 0;
  q[qt++] = 0;
  while (qh < qt) {
    int v = q[qh++];
    for (auto it : g[v]) {
      int to = e[it].to;
      if (d[to] == -1 && e[it].flow != e[it].cap) {
        d[to] = d[v] + 1;
        q[qt++] = to;
      }
    }
  }
  return d[finish] != -1;
}
int dfs(int v = start, int flow = inf) {
  if (v == finish || !flow) return flow;
  for (int &i = ptr[v]; i < g[v].size(); i++) {
    int it = g[v][i];
    int to = e[it].to;
    if (d[to] == d[v] + 1) {
      int push = dfs(to, min(flow, e[it].cap - e[it].flow));
      if (push) {
        e[it].flow += push;
        e[it ^ 1].flow -= push;
        return push;
      }
    }
  }
  return 0;
}
int MaxFlow() {
  int ans = 0;
  while (bfs()) {
    memset(ptr, 0, sizeof ptr);
    while (int push = dfs()) ans += push;
  }
  return ans;
}
vector<int> ans[N];
void go(int v, int col) {
  used[v] = col;
  ans[col].push_back(v);
  for (auto to : gg[v])
    if (used[to] == 0) go(to, col);
}
int main() {
  for (int i = 2; i < M; i++) pr[i] = 1;
  for (int i = 2; i < M; i++)
    if (pr[i])
      for (int j = i + i; j < M; j += i) pr[j] = 0;
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) {
    scanf("%d", &v[i]);
    if (v[i] % 2 == 0)
      a[++A] = i;
    else
      b[++B] = i;
  }
  start = 0, finish = n + 1;
  for (int i = 1; i <= A; i++) add_edge(start, i, 2);
  for (int i = 1; i <= A; i++)
    for (int j = 1; j <= B; j++)
      if (pr[v[a[i]] + v[b[j]]]) add_edge(i, A + j, 1);
  for (int i = 1; i <= B; i++) add_edge(i + A, finish, 2);
  int mx = MaxFlow();
  if (mx != n) {
    puts("Impossible");
    return 0;
  }
  for (auto it : e) {
    if (it.flow < 0 || it.flow != it.cap) continue;
    int u = a[it.from], v = b[it.to - A];
    if (u > v) swap(u, v);
    if (u == start || v == finish) continue;
    gg[u].push_back(v);
    gg[v].push_back(u);
  }
  int cnt = 0;
  for (int i = 1; i <= n; i++)
    if (used[i] == 0) go(i, ++cnt);
  printf("%d\n", cnt);
  for (int i = 1; i <= cnt; i++, puts("")) {
    printf("%d ", ans[i].size());
    for (auto it : ans[i]) printf("%d ", it);
  }
  return 0;
}