#include <iostream>
using namespace std;
int main()
{
int F,N;
cin >>F>>N;
int a[N],b[N];
b[0]=F;
for(int i=0;i<N;i++){
cin >> a[i];
}
b[1]=a[0];
for(int i=2;i<N;i++)b[i]=a[i-1];
for(int i=2;i<N;i++){
if(a[i-2]==a[i-1]&&a[i-1]==0)b[i]=5;
else if(a[i-2]==a[i-1]&&a[i-1]==2)b[i]=0;
else if(a[i-2]==a[i-1]&&a[i-1]==5)b[i]=2;
}
for(int i=0;i<N;i++){
if(a[i]==0&&b[i]==5){
cout << b[i]<<" : Won at round "<< i+1 << endl;
break;}
if(a[i]==2&&b[i]==0)
{
cout << b[i]<<" : Won at round "<< i+1 << endl;
break;}
if(a[i]==5&&b[i]==2)
{
cout << b[i]<<" : Won at round "<< i+1 << endl;
break;}
if(a[i]==5&&b[i]==0)
{
cout << b[i]<<" : Lost at round "<< i+1 << endl;
break;}
if(a[i]==0&&b[i]==2)
{
cout << b[i]<<" : Lost at round "<< i+1 << endl;
break;}
if(a[i]==2&&b[i]==5)
{
cout << b[i]<<" : Lost at round "<< i+1 << endl;
break;}
cout << b[i] << " ";
}
if(b[N-1]==a[N-1]){cout <<": Drew at round "<< N << endl;
}
return 0;
}