Dynamic arrays
Insert at index
Write a clear solution for this algorithm pattern. Use the typed function signature as your contract and explain the complexity in comments.
Manual review
Check the example, edge cases, and complexity.TypeScript is checked safely without execution.Validation reports TypeScript syntax and type diagnostics. Algorithm correctness stays a manual review.