Skip to content

Latest commit

 

History

History
12 lines (10 loc) · 591 Bytes

README.md

File metadata and controls

12 lines (10 loc) · 591 Bytes

Sort

Build a function that takes in an array of strings and outputs a new array with the same strings in alphabetical order.

  • Write a function that takes one parameter
    • Parameter 1 - An Array of strings
  • The function should output an array containing all the strings from the input array but in alphabetical order
  • Example: -var myArray = ['mouse', 'cat', 'dog', 'human'];
    • sort(myArray);
    • Output - ['cat', 'dog', 'human', 'mouse']
  • Try doing this using a Bubble Sort, if you are unsure what that is Click Here