def wind(x: int, a: int) -> int: return int(x/a+0.5) def main() -> None: t = int(input()) for i in range(t): d, a = map(int, input().split()) x = list(map(int, input().split())) w = list(map(wind, x, [a for i in range(d)])) for i in w: print(i, end=" ") print("") if __name__ == "__main__": main()