{"ScriptPreparationCode":"function shuffle(array) {\r\n var i = array.length,\r\n j = 0,\r\n temp;\r\n while (i--) {\r\n j = Math.floor(Math.random() * (i \u002B 1));\r\n temp = array[i];\r\n array[i] = array[j];\r\n array[j] = temp;\r\n }\r\n return array;\r\n}\r\nvar words = [\u0022aaa\u0022, \u0022bbb\u0022, \u0022ccc\u0022, \u0022AAA\u0022, \u0022BBB\u0022, \u0022CCC\u0022, \u0022123\u0022, \u0022234\u0022, \u0022345\u0022, \u0022aaa\u0022, \u0022bbb\u0022, \u0022ccc\u0022, \u0022AAA\u0022, \u0022BBB\u0022, \u0022CCC\u0022, \u0022123\u0022, \u0022234\u0022, \u0022345\u0022, \u0022aaa\u0022, \u0022bbb\u0022, \u0022ccc\u0022, \u0022AAA\u0022, \u0022BBB\u0022, \u0022CCC\u0022, \u0022123\u0022, \u0022234\u0022, \u0022345\u0022, \u0022aaa\u0022, \u0022bbb\u0022, \u0022ccc\u0022, \u0022AAA\u0022, \u0022BBB\u0022, \u0022CCC\u0022, \u0022123\u0022, \u0022234\u0022, \u0022345\u0022, \u0022\uAC00\uB098\uB2E4\u0022, \u0022\uB098\uB2E4\uB77C\u0022, \u0022\uB9C8\uBC14\uC0AC\u0022];\r\nvar words1 = [];\r\nvar n = [];\r\nfor (i = 0; i \u003C 4; i\u002B\u002B) words.push(...words);\r\nfor (i = 0; i \u003C words.length; i\u002B\u002B) n.push(i);\r\nvar ranNums = shuffle(n);\r\nfor (i = 0; i \u003C words.length; i\u002B\u002B) words1.push(words[ranNums[i]]);\r\nconsole.log(\u0027ORIGINAL\u0027, words1);","TestCases":[{"Name":"localeCompare","Code":"words1.sort((a,b) =\u003E a.localeCompare(b));","IsDeferred":false},{"Name":"lodash order","Code":"_.orderBy(words1,model =\u003E model,\u0027asc\u0027);","IsDeferred":false},{"Name":"sort comparator","Code":"words1.sort((a,b) =\u003E {\r\n if (a.toLowerCase() \u003C b.toLowerCase()) {\r\n return -1;\r\n }\r\n if (a.toLowerCase() \u003E b.toLowerCase()) {\r\n return 1;\r\n }\r\n return 0;\r\n});","IsDeferred":false}]}