This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//// Implementation | |
function play(from, to, rules) { | |
const lines = []; | |
for (let i = from; i <= to; i++) { | |
const message = rules | |
.filter(([word, predicate]) => predicate(i)) | |
.map(([word, predicate]) => word) | |
.join(""); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery(function() { | |
var $list = jQuery(".main-nav__accounts ul"); | |
$list.children("li") | |
.sort(function(a, b) { | |
return jQuery(a).text().trim().localeCompare(jQuery(b).text().trim()); | |
}) | |
.appendTo($list); | |
}); |