There are $$$n$$$ three-dimensional vectors, each of which can be marked as $$$\boldsymbol{x}=(x_1, x_2, x_3)$$$, where $$$x_1, x_2, x_3$$$ are integers.
ThomasX can choose a subset $$$S$$$ of the $$$n$$$ vectors, and calculate its sum, denoted by $$$\boldsymbol{y_S}=(y_{S_1}, y_{S_2}, y_{S_3})$$$. Please note that $$$S$$$ does not need to be a proper subset of the $$$n$$$ vectors, which means all the $$$n$$$ vectors can be in subset $$$S$$$.
Now ThomasX wants to calculate $$$\max_S \left\{\left|y_{S_1}\right|+\left|y_{S_2}\right|+\left|y_{S_3}\right|\right\}$$$. However, ThomasX has something much more important to accomplish, so he wants you to help him figure it out.
The first line contains an integer $$$n$$$ $$$(1 \leq n \leq 10^5)$$$, indicating the number of vectors.
Then $$$n$$$ lines follow. The $$$i$$$-th line contains three integers, indicating $$$x_1, x_2, x_3$$$ of the $$$i$$$-th vector respectively ($$$-10^4\le x_1,x_2,x_3\le 10^4$$$).
Output a line containing an integer indicating your answer.
3 3 -7 5 -2 4 8 6 0 -4
19
| Name |
|---|


