← All problemsSign in

A sky full of stars

Given a grid containing n rows and m columns, print the given pattern. Input - First line of input contains a single integer T denoting the number of test cases. For each test case, there will be single line containing two integers n and m. Output - For each test case, Print the required pattern. After each test case, print newline. Constraints - 1 ≤ T ≤ 5 - 1 ≤ n, m ≤ 40 Example

HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17

CodeSearch Tutor

Hints, not spoilers — it won’t hand over the full solution unless you insist.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start