#include<iostream>
#include<algorithm>
using namespace std;

const int TICKET_NUM = 8;
const int CITY_NUM = 30;
const double INF = 10000000000;

bool checkBit(char bit,int n) {
	int b = 1 << n;
	return  bit & b;
}

char setBit(char bit, int n) {
	int b = 1 << n;
	return bit | b;
}

int N, M, P, A, B;
int tickets[TICKET_NUM];
int route[CITY_NUM][CITY_NUM] = { {0} };
double dp[256][30];

double solve(unsigned char t, int c) {
	if (dp[t][c] != -1)return dp[t][c];
	if (c == B) {
		return 0;
	}
	double m = INF;
	for (int i = 0; i < N; i++) {
		if (checkBit(t, i))continue;
		for (int j = 0; j < M; j++) {
			if (route[c][j] == 0)continue;
			double time = route[c][j] / (double)tickets[i];
			m = min(m, solve(setBit(t, i), j) + time);
		}
	}
	return dp[t][c] = m;
}

int main() {

	while (true) {
		for (int i = 0; i < CITY_NUM; i++) {
			for (int j = 0; j < CITY_NUM; j++) {
				route[i][j] = 0;
			}
		}
		for (int i = 0; i < 256; i++) {
			for (int j = 0; j < CITY_NUM; j++) {
				dp[i][j] = -1;
			}
		}

		cin >> N >> M >> P >> A >> B;
		A--; B--;
		if (N == 0)break;
		for (int i = 0; i < N; i++) {
			cin >> tickets[i];
		}

		for (int i = 0; i < P; i++) {
			int x, y, z;
			cin >> x >> y >> z;
			x--; y--;
			route[x][y] = z;
			route[y][x] = z;
		}
		double ans = solve(0, A);
		if (ans == INF) {
			cout << "Impossible" << endl;
		}
		else {
			cout << ans << endl;
		}
	}

	return 0;
}