#include<iostream>
#include<stdio.h>
#include<math.h>
#include<stdlib.h>

using namespace std;

int main()
{int N,K,x,p1=0,p2=0,p3=0,pu=0;
cin>>N;
cin>>k;
while(N>0)
{cin>>x;
if(x==-1){p1++;}
if(x==0){p2++;}
if(x==1){p3++;}

N--;
}
if(p1>=k)pu++;
if(p1>=k)++;
if(p3>=k)pu++;
printf("%d\n",pu);
if(p1>=k)printf("%d ",p1);
if(p2>=k)printf("%d ",p2);
if(p3>=k)printf("%d ",p3);

    return 0;
}