Skip to content

Instantly share code, notes, and snippets.

@ravidaram
Last active December 20, 2015 13:09
Show Gist options
  • Save ravidaram/6136564 to your computer and use it in GitHub Desktop.
Save ravidaram/6136564 to your computer and use it in GitHub Desktop.
arraysjs
<html lang="en">
<head>
<title><!-- Insert your title here --></title>
</head>
<body>
<script>
var strings=["a", "abcdefghijkl","ab","abcdefg","abcd"]
strings.sort();
strings.reverse();
strings.sort();
var counter=0;
for (counter=0; counter<strings.length; counter++)
document.write(strings[counter] + "<br>");
</script>
</script>
<!-- Insert your content here -->
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment