---
title: "Discussion on \"Sorting arrays in JavaScript\" | Hashnode"
description: "Discussion on \"Sorting arrays in JavaScript\". This is the second article in The JavaScript Snippet Series. In the  previous episode we discussed three methods of getting unique values from JavaScript. In this article, we will discuss various ways of sorting arrays in JavaScript.\nSorting is a com..."
url: "https://hashnode.com/posts/sorting-arrays-in-javascript/5f06c89e590b261f9b0342fe"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Sorting arrays in JavaScript](https://bytenaija.hashnode.dev/sorting-arrays-in-javascript?utm_source=hashnode&utm_medium=feed)

This is the second article in The JavaScript Snippet Series. In the previous episode we discussed three methods of getting unique values from JavaScript. In this article, we will discuss various ways of sorting arrays in JavaScript. Sorting is a com...

Jul 9, 2020 · 5 min read · bytenaija.hashnode.dev  
Read the article

-   [#javascript](https://hashnode.com/tag/javascript)
-   [#snippets](https://hashnode.com/tag/snippets)
-   [#algorithms](https://hashnode.com/tag/algorithms)
-   [#sorting](https://hashnode.com/tag/sorting)
-   [#2articles1week](https://hashnode.com/tag/2articles1week)

## Written by

[Everistus Olumese](https://hashnode.com/@bytenaija)

@bytenaija · Toronto/Canada

  
[View profile](https://hashnode.com/@bytenaija)

Senior Fullstack Engineer @ jewlr.com

I am a developer from Lagos, Nigeria with over 7 years of professional experience.

## Responses 1

Markdown supported · ⌘↵ to post

[Chris Bongers](https://hashnode.com/@dailydevtips)

[Jul 9, 2020](https://hashnode.com/posts/sorting-arrays-in-javascript/5f06c89e590b261f9b0342fe/comment/5f06d0c6590b261f9b03431e)

Very nice write-up, keep in mind for big arrays this is not the best option since it will slow down quickly. The numbers you are testing with seem valid enough.

[Everistus Olumese](https://hashnode.com/@bytenaija)

[Jul 9, 2020](https://hashnode.com/posts/sorting-arrays-in-javascript/5f06c89e590b261f9b0342fe/comment/5f06d0c6590b261f9b03431e#reply-5f06ecb9e9578924182addeb)

This is absolutely correct
