Can we use counting sort for this?

Can we use counting sort for this ?

@kunaldude04 hey kunal offcourse you can use that.