#include<bits/stdc++.h>
typedef long long int ll;
typedef unsigned long long int ull;
#define BIG_NUM 2000000000
#define HUGE_NUM 99999999999999999
#define MOD 1000000007
#define EPS 0.000000001
using namespace std;


enum LOC{
	CENTER,
	SOUTH,
	EAST,
	WEST,
	NORTH,
	UNDER,
};

//0:中央 1:南 2:東 3:西 4:北 5:裏側
struct Dice{

	void roll(char dst){

		for(int i = 0; i < 6; i++) work[i] = number[i];

		switch(dst){
		case 'E':
			setNumber(work[3],work[1],work[0],work[5],work[4],work[2]);
			break;
		case 'N':
			setNumber(work[1],work[5],work[2],work[3],work[0],work[4]);
			break;
		case 'S':
			setNumber(work[4],work[0],work[2],work[3],work[5],work[1]);
			break;
		case 'W':
			setNumber(work[2],work[1],work[5],work[0],work[4],work[3]);
			break;
		}
	}

	bool is_ok(){

		for(int i = 0; i < 6; i++){
			if(number[i] < 0){
				return false;
			}
		}

		int sum_A = number[CENTER]+number[UNDER];
		int sum_B = number[SOUTH]+number[NORTH];
		int sum_C = number[EAST]+number[WEST];

		return (sum_A <= sum_B+sum_C) && (sum_B <= 1+sum_A+sum_C) && (sum_C <= 1+sum_A+sum_B);
	}

	void setNumber(int n0,int n1,int n2,int n3,int n4,int n5){
		number[CENTER] = n0;
		number[SOUTH] = n1;
		number[EAST] = n2;
		number[WEST] = n3;
		number[NORTH] = n4;
		number[UNDER] = n5;
	}

	int number[6],work[6];
};

int table_index;
int tmp_array[6];
int table[720][6];
int T[6];
int L,R;
int length;
bool used[6],total_FLG,current_FLG;
char dir_array[4] = {'E','N','S','W'},rev_dir_array[4] = {'W','S','N','E'};
char ANS[30005],TMP[30005];


void makeTable(int index){

	if(index == 6){

		for(int i = 0; i < 6; i++){
			table[table_index][i] = tmp_array[i];
		}
		table_index++;

		return;
	}

	for(int next = 0; next < 6; next++){
		if(used[next])continue;
		used[next] = true;
		tmp_array[index] = next;
		makeTable(index+1);
		used[next] = false;
	}
}

void recursive(int index,Dice dice,bool is_solo_leader){

	if(current_FLG)return;

	if(index == length){

		total_FLG = true;
		current_FLG = true;

		for(int i = 0; i < length; i++){
			ANS[i] = TMP[i];
		}
		return;
	}

	for(int i = 0; i < 4; i++){
		dice.roll(dir_array[i]);
		dice.number[UNDER]--;

		if(dice.is_ok()){

			if(is_solo_leader){ //単独1位

				TMP[index] = dir_array[i];
				recursive(index+1,dice,true);

			}else{

				if(total_FLG){

					if(dir_array[i] < ANS[index]){

						TMP[index] = dir_array[i];
						recursive(index+1,dice,true);

					}else if(dir_array[i] == ANS[index]){

						TMP[index] = dir_array[i];
						recursive(index+1,dice,false);
					}

				}else{
					//Do nothing
				}
			}
		}

		dice.number[UNDER]++;
		dice.roll(rev_dir_array[i]);
	}
}

void func(){

	total_FLG = false;

	length = 0;

	for(int i = 0; i < 6; i++){
		length += T[i];
	}

	for(int i = 0; i < table_index; i++){

		Dice dice;

		for(int k = 0; k < 6; k++){
			dice.number[k] = T[table[i][k]];
		}
		current_FLG = false;

		if(total_FLG){
			recursive(0,dice,false);
		}else{
			recursive(0,dice,true);
		}
	}

	if(!total_FLG){

		printf("impossible\n");

	}else{

		for(int i = L; i <= R; i++){
			printf("%c",ANS[i]);
		}
		printf("\n");
	}
}

int main(){

	for(int i = 0; i < 6; i++){
		used[i] = false;
	}

	table_index = 0;

	for(int first = 0; first < 6; first++){

		used[first] = true;
		tmp_array[0] = first;
		makeTable(1);
		used[first] = false;
	}

	while(true){

		for(int i = 0; i < 6; i++){

			scanf("%d",&T[i]);
		}
		if(T[0]+T[1]+T[2]+T[3]+T[4]+T[5] == 0)break;

		scanf("%d %d",&L,&R);
		L--;
		R--;

		func();
	}

	return 0;
}



Measured memory_bytes: 6976