#include <bits/stdc++.h>
#define ff first
#define ss second
#define ALL_THE(CAKE,LIE) for(auto LIE =CAKE.begin(); LIE != CAKE.end(); LIE++)
using namespace std;

int main() {
	int M,N,st,fin;
	while(scanf(" %d %d %d %d",&M,&N,&st,&fin)) {
		if(M == 0) return 0;
		vector< vector< pair<int,long long> > > G(N);
		st--, fin--;
		for(int i =0; i < M; i++) {
			int a,b;
			double c;
			scanf(" %d %d %lf",&a,&b,&c);
			int C =(int)(c*1000);
			while(C > c*1000+0.1) C--;
			if(C < c*1000-0.1) C++;
			G[--a].push_back(make_pair(--b,-C));}
		vector<long long> D(N,1e15);
		D[st] =0;
		vector<bool> ncyc(N,false),vis(N,false);
		priority_queue< pair<long long,int>, vector< pair<long long,int> >, greater< pair<long long,int> > > q;
		q.push(make_pair(0,st));
		long long minf =-1000000000000000LL;
		vis[st] =true;
		while(!q.empty()) {
			pair<double,int> p =q.top();
			q.pop();
			if(D[p.ss] != p.ff) continue;
			vis[p.ss] =true;
			ALL_THE(G[p.ss],it) {
				long long d =p.ff+it->ss;
				if(ncyc[p.ss]) d =minf;
				if(d < D[it->ff]) {
					if(vis[it->ff]) ncyc[it->ff] =true;
					D[it->ff] =d;
					q.push(make_pair(d,it->ff));}
				}
			}
		if(D[fin] < 0) printf("TRUE\n");
		else printf("FALSE\n");}
	}