The input contains several test cases and the first line is the total number of cases $T~(1\le T\le 300)$.
Each case describes a network $G$, and the first line contains two integers $n~(2\le n\le 200)$ and $m~(0\le m\le 1000)$ indicating the sizes of nodes and edges. All nodes in the network are labelled from $1$ to $n$.
The second line contains two different integers $s$ and $t~(1\le s,t\le n)$ corresponding to the source and sink.
Each of the next $m$ lines contains three integers $u,v$ and $w~(1\le w\le 255)$ describing a directed edge from node $u$ to $v$ with capacity $w$.