Difference between revisions of "Sandbox3"
Jump to navigation
Jump to search
| (One intermediate revision by one other user not shown) | |||
| Line 1: | Line 1: | ||
| + | <source lang="javascript" line start="2" highlight="4-6"> | ||
| + | // SyntaxHighlighter makes your code snippets beautiful without tiring your servers. | ||
| + | // http://alexgorbatchev.com | ||
| + | var setArray = function(elems) { | ||
| + | this.length = 0; | ||
| + | push.apply(this, elems); | ||
| + | return this; | ||
| + | } | ||
| + | </source> | ||
| + | |||
| + | |||
| + | |||
<syntaxhighlight lang="python"> | <syntaxhighlight lang="python"> | ||
#/usr/bin/env python3 | #/usr/bin/env python3 | ||
| + | def quick_sort(arr): | ||
| + | less = [] | ||
| + | pivot_list = [] | ||
| + | more = [] | ||
| + | if len(arr) <= 1: | ||
| + | return arr | ||
| + | else: | ||
| + | pass | ||
| + | </syntaxhighlight> | ||
| + | |||
| + | |||
| + | <syntaxhighlight lang="python" line='line'> | ||
def quick_sort(arr): | def quick_sort(arr): | ||
less = [] | less = [] | ||
Latest revision as of 20:35, 18 January 2020
2 // SyntaxHighlighter makes your code snippets beautiful without tiring your servers.
3 // http://alexgorbatchev.com
4 var setArray = function(elems) {
5 this.length = 0;
6 push.apply(this, elems);
7 return this;
8 }
<h1>/usr/bin/env python3</h1>
def quick_sort(arr):
less = []
pivot_list = []
more = []
if len(arr) <= 1:
return arr
else:
pass
1 def quick_sort(arr):
2 less = []
3 pivot_list = []
4 more = []
5 if len(arr) <= 1:
6 return arr
7 else:
8 pass