#include <bits/stdc++.h>
using namespace std;
const int N = 100005;
inline int IN() {
  char ch;
  (ch = getchar());
  int f = 0, x = 0;
  for (; ((ch) == '\n' || (ch) == '\r' || (ch) == '\t' || (ch) == ' ');
       (ch = getchar()))
    ;
  if (ch == '-') f = 1, (ch = getchar());
  for (; !((ch) == '\n' || (ch) == '\r' || (ch) == '\t' || (ch) == ' ');
       (ch = getchar()))
    x = x * 10 + ch - '0';
  return (f) ? (-x) : (x);
}
int Pow(int x, int y, int p) {
  int A = 1;
  for (; y; y >>= 1, x = (long long)x * x % p)
    if (y & 1) A = (long long)A * x % p;
  return A;
}
struct edge {
  int u, v, w, pre;
} e[N];
int dex, adj[N];
int n, m, k, L[N], R[N], s1, s2, t;
long long dis[2][N];
int Q[N * 50], l, r, vis[N], tim;
void spfa(long long *dis, int s) {
  for (int i = (int)1; i <= (int)n; i++) dis[i] = 1e10;
  ++tim;
  dis[s] = 0;
  vis[Q[l = r = 1] = s] = tim;
  for (int i = (int)1; i <= (int)r; i++) {
    int u = Q[i];
    for (int i = adj[u]; i; i = e[i].pre) {
      int v = e[i].v;
      if (dis[u] + e[i].w < dis[v]) {
        dis[v] = dis[u] + e[i].w;
        if (vis[v] ^ tim) vis[Q[++r] = v] = tim;
      }
    }
    vis[u] = 0;
  }
}
void Return(string s) {
  cout << s << endl;
  if (s != "LOSE") {
    for (int i = (int)m + 1; i <= (int)k + m; i++) printf("%d ", e[i].w);
    puts("");
    exit(0);
  }
}
void work() {
  spfa(dis[0], s1);
  spfa(dis[1], s2);
  if (dis[0][t] < dis[1][t]) Return("WIN");
  bool mark = 1;
  while (mark) {
    mark = 0;
    for (int i = (int)1 + m; i <= (int)k + m; i++) {
      if (dis[0][e[i].u] < dis[1][e[i].u] && e[i].w == R[i]) {
        e[i].w = L[i];
        spfa(dis[0], s1);
        spfa(dis[1], s2);
        if (dis[0][t] < dis[1][t]) Return("WIN");
        mark = 1;
      }
      if (dis[0][e[i].u] > dis[1][e[i].u] && e[i].w == L[i]) {
        e[i].w = R[i];
        spfa(dis[0], s1);
        spfa(dis[1], s2);
        if (dis[0][t] < dis[1][t]) Return("WIN");
        mark = 1;
      }
    }
  }
  Return(dis[0][t] == dis[1][t] ? "DRAW" : "LOSE");
}
int main() {
  scanf("%d%d%d", &n, &m, &k);
  scanf("%d%d%d", &s1, &s2, &t);
  for (int i = (int)1; i <= (int)m; i++) {
    int x = IN(), y = IN(), w = IN();
    e[i] = (edge){x, y, w, adj[x]};
    adj[x] = i;
  }
  for (int i = (int)m + 1; i <= (int)m + k; i++) {
    int x = IN(), y = IN(), l = IN(), r = IN();
    e[i] = (edge){x, y, r, adj[x]};
    adj[x] = i;
    L[i] = l;
    R[i] = r;
  }
  work();
  return 0;
}
