You are given two positive integers $n$ ($1 \le n \le 10^9$) and $k$ ($1 \le k \le 100$). Represent the number $n$ as the sum of $k$ positive integers of the same parity (have the same remainder when divided by $2$).

In other words, find $a_1, a_2, \ldots, a_k$ such that all $a_i>0$, $n = a_1 + a_2 + \ldots + a_k$ and either all $a_i$ are even or all $a_i$ are odd at the same time.

If such a representation does not exist, then report it.


-----Input-----

The first line contains an integer $t$ ($1 \le t \le 1000$) — the number of test cases in the input. Next, $t$ test cases are given, one per line.

Each test case is two positive integers $n$ ($1 \le n \le 10^9$) and $k$ ($1 \le k \le 100$).


-----Output-----

For each test case print:

  YES and the required values $a_i$, if the answer exists (if there are several answers, print any of them);  NO if the answer does not exist. 

The letters in the words YES and NO can be printed in any case.


-----Example-----
Input
8
10 3
100 4
8 7
97 2
8 8
3 10
5 3
1000000000 9

Output
YES
4 2 4
YES
55 5 5 35
NO
NO
YES
1 1 1 1 1 1 1 1
NO
YES
3 1 1
YES
111111110 111111110 111111110 111111110 111111110 111111110 111111110 111111110 111111120
[{"code": "t=int(input())\nfor i in range (t):\n    n,k=map(int,input().split())\n    if n-k+1>0 and (n-k+1)%2==1:\n        print(\"YES\")\n        print(*([1]*(k-1)), n-k+1)\n    elif n-k*2+2>0 and (n-k*2+2)%2==0:\n        print(\"YES\")\n        print(*([2]*(k-1)), n-k*2+2)\n    else:\n        print(\"NO\")", "passed": true, "time": 0.14, "memory": 14280.0, "status": "done"}, {"code": "for _ in range(int(input())):\n    n, k = list(map(int, input().split()))\n    if k % 2 == 1:\n        if n % 2 == 0:\n            if 2*k <= n:\n                print('YES')\n                print(*[2]*(k-1), n-2*(k-1))\n            else:\n                print('NO')\n        else:\n            if k <= n:\n                print('YES')\n                print(*[1]*(k-1), n-k+1)\n            else:\n                print('NO')\n    else:\n        if k <= n and n % 2 == 0:\n            print('YES')\n            print(*[1]*(k-1), n-k+1)\n        else:\n            print('NO')\n", "passed": true, "time": 0.14, "memory": 14200.0, "status": "done"}, {"code": "import sys\n\nreadline = sys.stdin.readline\nreadlines = sys.stdin.readlines\nns = lambda: readline().rstrip()\nni = lambda: int(readline().rstrip())\nnm = lambda: map(int, readline().split())\nnl = lambda: list(map(int, readline().split()))\nprn = lambda x: print(*x, sep='\\n')\n\n\ndef solve():\n    n, k = nm()\n    l = [1]*(k-1) + [n-k+1]\n    if l[-1] > 0 and l[-1] % 2:\n        print('YES')\n        print(*l)\n        return\n    l = [2]*(k-1) + [n - 2*(k-1)]\n    if l[-1] > 0 and l[-1] % 2 == 0:\n        print('YES')\n        print(*l)\n        return\n    print('NO')\n    return\n\n# solve()\n\nT = ni()\nfor _ in range(T):\n    solve()\n", "passed": true, "time": 0.14, "memory": 14140.0, "status": "done"}, {"code": "for _ in range(int(input())):\n    n, k = map(int, input().split())\n    odd = n - k + 1\n    even = n - ((k-1) * 2)\n    if odd > 0 and odd % 2 == 1:\n        print('YES')\n        print('1 ' * (k-1), odd, sep='')\n    elif even > 0 and even % 2 == 0:\n        print('YES')\n        print('2 ' * (k-1), even, sep='')\n    else:\n        print('NO')", "passed": true, "time": 0.22, "memory": 14080.0, "status": "done"}, {"code": "for i in range(int(input())):\n  n,k=[int(i) for i in input().split()]\n  if k>n:\n    print('NO')\n  elif (n-k+1)%2==1 and n-k+1>0:\n    print('YES')\n    for i in range(k-1):\n      print(1,end=' ')\n    print(n-k+1)\n  elif  (n-2*(k-1))%2==0 and n-2*(k-1)>0:\n    print('YES')\n    for i in range(k-1):\n      print(2,end=' ')\n    print(n-2*(k-1))\n  else:\n    print('NO')\n", "passed": true, "time": 0.14, "memory": 14380.0, "status": "done"}, {"code": "import sys\nimport os\nimport time\nimport collections\nfrom collections import Counter, deque\nimport itertools\nimport math\nimport timeit\nimport random\nimport string\n\n#########################\n# imgur.com/Pkt7iIf.png #\n#########################\n\ndef sieve(n):\n    if n < 2: return list()\n    prime = [True for _ in range(n + 1)]\n    p = 3\n    while p * p <= n:\n        if prime[p]:\n            for i in range(p * 2, n + 1, p):\n                prime[i] = False\n        p += 2\n    r = [2]\n    for p in range(3, n + 1, 2):\n        if prime[p]:\n            r.append(p)\n    return r\n\ndef divs(n, start=1):\n    divisors = []\n    for i in range(start, int(math.sqrt(n) + 1)):\n        if n % i == 0:\n            if n / i == i:\n                divisors.append(i)\n            else:\n                divisors.extend([i, n // i])\n    return divisors\n\ndef divn(n, primes):\n    divs_number = 1\n    for i in primes:\n        if n == 1:\n            return divs_number\n        t = 1\n        while n % i == 0:\n            t += 1\n            n //= i\n        divs_number *= t\n\ndef flin(d, x, default=-1):\n    left = right = -1\n    for i in range(len(d)):\n        if d[i] == x:\n            if left == -1: left = i\n            right = i\n    if left == -1:\n        return default, default\n    else:\n        return left, right\n\ndef ceil(n, k): return n // k + (n % k != 0)\ndef ii(): return int(input())\ndef mi(): return list(map(int, input().split()))\ndef li(): return list(map(int, input().split()))\ndef lcm(a, b): return abs(a * b) // math.gcd(a, b)\ndef prr(a, sep=' '): print(sep.join(map(str, a)))\ndef dd(): return collections.defaultdict(int)\ndef ddl(): return collections.defaultdict(list)\n\n########################################################################################################################\n# input = sys.stdin.readline\n\nfor _ in range(ii()):\n    n, k = mi()\n    even = n - 2*(k - 1)\n    odd = n - (k - 1)\n    if odd > 0 and odd % 2:\n        res = [1]*(k - 1) + [odd]\n        print('YES')\n        prr(res, ' ')\n    elif even > 0 and even % 2 == 0:\n        res = [2] * (k - 1) + [even]\n        print('YES')\n        prr(res, ' ')\n    else:\n        print('NO')\n", "passed": true, "time": 1.43, "memory": 14244.0, "status": "done"}, {"code": "t = int(input())\nfor _ in range(t):\n    n, k = list(map(int, input().split()))\n    ans = []\n    if n % 2 == 0:\n        if k % 2 == 0:\n            for i in range(k-1):\n                ans.append(1)\n                n -= 1\n            ans.append(n)\n\n        else:\n            for i in range(k-1):\n                ans.append(2)\n                n -= 2\n            ans.append(n)\n\n    else:\n        if k % 2 == 0:\n            ans.append(-1)\n        else:\n            for i in range(k-1):\n                ans.append(1)\n                n -= 1\n            ans.append(n)\n    if min(ans) <= 0:\n        print(\"NO\")\n    else:\n        print(\"YES\")\n        print(*ans)\n", "passed": true, "time": 0.23, "memory": 14344.0, "status": "done"}, {"code": "t = int(input())\nfor _ in range(t):\n\tn, k = map(int, input().split())\n\tif k%2 == 0 and n%2 == 1:\n\t\tprint(\"NO\")\n\telif (k%2 == 1 and n%2 == 0 and n < 2*k) or n < k:\n\t\tprint(\"NO\")\n\telif k%2 == 1 and n%2 == 0:\n\t\tprint(\"YES\")\n\t\tans = [2] * (k-1) + [n-2*(k-1)]\n\t\tprint(*ans)\n\telse:\n\t\tprint(\"YES\")\n\t\tans = [1] * (k-1) + [n-k+1]\n\t\tprint(*ans)", "passed": true, "time": 1.31, "memory": 14256.0, "status": "done"}, {"code": "for t in range(int(input())):\n    n,k = map(int,input().split())\n    if n < k:\n        print(\"NO\")\n    elif n%2==k%2:\n        print(\"YES\")\n        print(*([1]*(k-1)+[n-(k-1)]))\n    elif n%2==0 and n >= 2*k-1:\n        print(\"YES\")\n        print(*([2]*(k-1)+[n-2*(k-1)]))\n    else:\n        print(\"NO\")", "passed": true, "time": 0.14, "memory": 14240.0, "status": "done"}, {"code": "import sys\ninput = sys.stdin.readline\n\nt=int(input())\nfor tests in range(t):\n    n,k=list(map(int,input().split()))\n\n    if n%2==k%2 and n>=k:\n        print(\"YES\")\n        ANS=[1]*(k-1)+[n-(k-1)]\n        print(*ANS)\n\n    elif n%2==0 and n>=2*k:\n        print(\"YES\")\n        ANS=[2]*(k-1)+[n-2*(k-1)]\n        print(*ANS)\n    else:\n        print(\"NO\")\n        \n        \n        \n", "passed": true, "time": 0.14, "memory": 14108.0, "status": "done"}, {"code": "import math,sys\nfrom sys import stdin, stdout\nfrom collections import Counter, defaultdict, deque\ninput = stdin.readline\nI = lambda:int(input())\nli = lambda:list(map(int,input().split()))\n\ndef case():\n    n,k=li()\n    if(k>n):\n        print(\"NO\")\n        return()\n    if((n-k-1)%2):\n        print(\"YES\")\n        for i in range(k-1):\n            print(1,end=\" \")\n        print(n+1-k)\n        return \n    if(n-2*k<0):\n        print(\"NO\")\n        return \n    else:\n        \n        if((n-2*k-2)%2==0):\n            print(\"YES\")\n            for i in range(k-1):\n                print(2,end=\" \")\n            print(n-2*k+2)\n        else:\n            print(\"NO\")     \nfor _ in range(int(input())):\n    case()", "passed": true, "time": 0.14, "memory": 14120.0, "status": "done"}, {"code": "import math\nfor _ in range(int(input())):\n\tn,k=list(map(int,input().split()))\n\tif n<k:\n\t\tprint(\"NO\")\n\telse:\n\t\tif n%2==0:\n\t\t\tif k%2==0:\n\t\t\t\td=[]\n\t\t\t\tfor i in range(k-1):\n\t\t\t\t\td.append(1)\n\t\t\t\td.append(n-k+1)\n\t\t\t\tprint(\"YES\")\n\t\t\t\tprint(*d)\n\t\t\telse:\n\t\t\t\tif n<2*k:\n\t\t\t\t\tprint(\"NO\")\n\t\t\t\telse:\n\t\t\t\t\td=[]\n\t\t\t\t\tfor i in range(k-1):\n\t\t\t\t\t\td.append(2)\n\t\t\t\t\td.append(n-2*(k-1))\n\t\t\t\t\tprint(\"YES\")\n\t\t\t\t\tprint(*d)\n\t\telse:\n\t\t\tif k%2==1:\n\t\t\t\td=[]\n\t\t\t\tfor i in range(k-1):\n\t\t\t\t\td.append(1)\n\t\t\t\td.append(n-k+1)\n\t\t\t\tprint(\"YES\")\n\t\t\t\tprint(*d)\n\t\t\telse:\n\t\t\t\tprint(\"NO\")\n\n\n\n\t\n", "passed": true, "time": 0.14, "memory": 14120.0, "status": "done"}]