Given a positive integer n, generate an n x n matrix filled with elements from 1 to n² in spiral order.
Generate 3×3 spiral matrix