#i. 1IXMMMlOP0wTWg#&:;.
1IXMMMlOP0wTWg#&:;.
该比赛已结束,您无法在比赛模式下递交该题目。您可以点击“在题库中打开”以普通模式查看和递交本题。
Statement
You are given a coordinate plane and three integers , , and . Find two line segments and such that
- the coordinates of points , , , and are integers;
- and ;
- the length of segment is at least ;
- the length of segment is at least ;
- segments and are perpendicular: if you draw lines that contain and , they will cross at a right angle.
Note that it's not necessary for segments to intersect. Segments are perpendicular as long as the lines they induce are perpendicular.
Format
Input
The first line contains a single integer ( ) — the number of test cases. Next, cases follow.
The first and only line of each test case contains three integers , , and ( ; ).
Additional constraint on the input: the values of , , and are chosen in such a way that the answer exists.
Output
For each test case, print two lines. The first line should contain integers , , , and — the coordinates of the first segment.
The second line should also contain integers , , , and — the coordinates of the second segment.
If there are multiple answers, print any of them.
Sample
4
1 1 1
3 4 1
4 3 3
3 4 4
0 0 1 0
0 0 0 1
2 4 2 2
0 1 1 1
0 0 1 3
1 2 4 1
0 1 3 4
0 3 3 0
ShanghaiTech ACM 炸鱼杯
- 状态
- 已结束
- 规则
- OI
- 题目
- 46
- 开始于
- 2024-12-10 23:00
- 结束于
- 2024-12-15 13:00
- 持续时间
- 110 小时
- 主持人
- 参赛人数
- 112