Join p and q so the result is (4, 2) — one on top of the other

NumPy · from Joining and splitting arrays

np.concatenatenp.stacknp.vstacknp.hstacknp.splitnp.tilenp.repeat

Putting the kettle on…

Starting up…

Exercise 1

Join p and q so the result is (4, 2) — one on top of the other.

your answer
stuck? the lesson behind it
Joining and splitting arrays
concatenate extends an axis; stack creates one. Everything else is shorthand.