#P1809C. Sum on Subarrays
Sum on Subarrays
No submission language available for this problem.
Description
For an array , let's denote its subarray as the array .
For example, the array has non-empty subarrays:
- ;
- ;
- ;
- ;
- ;
- .
You are given two integers and . Construct an array consisting of integers such that:
- all elements of are from to ;
- has exactly subarrays with positive sums;
- the rest subarrays of have negative sums.
The first line contains one integer () — the number of test cases.
Each test case consists of one line containing two integers and (; ).
For each test case, print integers — the elements of the array meeting the constraints. It can be shown that the answer always exists. If there are multiple answers, print any of them.
Input
The first line contains one integer () — the number of test cases.
Each test case consists of one line containing two integers and (; ).
Output
For each test case, print integers — the elements of the array meeting the constraints. It can be shown that the answer always exists. If there are multiple answers, print any of them.