Menu
Coddy logo textTech

Final Challenge #2

Lesson 9 of 9 in Coddy's Quick Sort - DSA Series course.

challenge icon

Challenge

Medium

One more challenge to master partitioning.

Write quickSort so it returns the array sorted in ascending order with duplicates removed, so every value appears exactly once.

For example, [3, 1, 2, 3, 1] becomes [1, 2, 3].

Try it yourself

#include <stdlib.h>

int* quickSort(int* arr, int arr_size, int* returnSize) {
    // Write code here
    *returnSize = arr_size;
    return arr;
}

All lessons in Quick Sort - DSA Series