This file contains hidden or 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
#!/bin/bash | |
printf 'This is \e[4:3mmono undercurl\e[0m,\n' | |
printf 'and this is \e[4:3m\e[58:2:206:64:51mcolor undercurl\e[0m.\n' |
This file contains hidden or 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
const fibo = n => { | |
if (n <= 1) { | |
return n; | |
} | |
else { | |
return fibo(n-1) + fibo(n-2); | |
} | |
} | |
for (let n of process.argv.slice(2)) { |
This file contains hidden or 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
const bubble_sort = (arr) => { | |
const n = arr.length; | |
for (let i = 0; i < n; i++) { | |
for (let j = 0; j < n - i - 1; j++) { | |
if (arr[j] > arr[j + 1]) { | |
[arr[j], arr[j + 1]] = [arr[j + 1], arr[j]]; | |
} | |
} | |
} | |
return arr; |
OlderNewer