Practice ยท 1 of 4
Allocate 1..n
Implement int* ints_up_to(int n) returning a heap-allocated array holding 1,2,...,n. Return NULL for n <= 0. The CALLER frees it.
Difficulty: beginner
Press Submit to check your solution.
Back to lesson: Practice: Allocation Workbench