#include <iostream>
#include <algorithm>

#define INF 99999999

using namespace std;

int main(void){
	while(1){
		int n, m, p, a, b; cin >> n >> m >> p >> a >> b;
		if(!n && !m && !p && !a && !b) break;

		int t[10]={0};
		int cost[30][30]; fill(cost[0], cost[29], -1);
		double dp[(1<<8)+1][30]; fill(dp[0], dp[(1<<8)], INF);
		for(int i=0; i<n; i++){
			cin >> t[i];
		}
		for(int i=0; i<p; i++){
			int x, y, z; cin >> x >> y >> z;
			x--; y--;
			cost[x][y] = cost[y][x] = z;
		}
		dp[(1<<n)-1][b-1] = 0;
		double ans = INF;
		for(int s=(1<<n)-1; s>=0; s--){
			ans = min(ans, dp[s][a-1]);

			for(int v=0; v<m; v++){
				for(int i=0; i<n; i++){
					if(s >> i & 1){
						for(int u=0; u<m; u++){
							if(cost[v][u] >= 0){
								dp[s & ~(1<<i)][u] = min(dp[s & ~(1<<i)][u], dp[s][v]+(double)cost[v][u]/t[i]);
							}
						}
					}
				}
			}
		}
		if(ans == INF) cout << "Impossible" << endl;
		else cout << ans << endl;
	}
	return 0;
}
