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
pgrep -a -i twitch | xargs ps -o ni -p | |
pgrep -a -i twitch | sudo xargs renice "-3" | |
pgrep -a -i twitch | xargs ps -o ni -p |
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
#!/usr/bin/env zx | |
cd(`/Users/tarasmazepa`); | |
await $`rm temp.mp4 temp.mkv audio.mp3`.nothrow(); | |
const script = | |
argv._[0] + | |
" Let me know in the comments what other life situation you want me to talk next. Subscribe, follow, and give a like to hear more stories like this."; | |
const ssml = `<speak>${script | |
.replace(/([.?!])\s*(?=[A-Z])/g, "$1|") | |
.split("|") | |
.filter((s) => s.length > 0) |
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
LIKE EVERYONE ELSE, DOCTORS ENJOY being recognized for their achievements. One sure way of attaining medical fame is to discover a new disease or to solve a particularly daunting medical puzzle. And the physicians at one Texas hospital where I consulted saw the little girl in room 723E as such a challenge. At four years old, Laura weighed just twenty-six pounds, despite having been fed a high-calorie diet via a tube inserted through her nose for weeks. The stack of her medical files that confronted me at the nurses’ station was about four feet high, taller than the shrunken little girl herself. Laura’s story, like that of the children of Waco, helped us learn more about how children respond to early experience. It illustrates how the mind and body cannot be treated separately, reveals what infants and young children need for healthy brain development and demonstrates how neglecting those needs can have a profound impact on every aspect of a child’s growth. | |
Laura’s files contained literally thousands of pages |
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
#!/usr/bin/env zx | |
cd(`/Users/tarasmazepa`); | |
await $`rm temp.mp4 temp.mkv audio.mp3`.nothrow(); | |
const script = | |
argv._[0] + | |
" Let me know in the comments what other life situation you want me to talk next. Subscribe, follow, and give a like to hear more stories like this."; | |
const ssml = `<speak>${script | |
.replace(/([.?!])\s*(?=[A-Z])/g, "$1|") | |
.split("|") | |
.filter((s) => s.length > 0) |
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
return res.send(`# Collection id: ${collection.id} | |
### Collection name: | |
${collection.data().title} | |
### Collection description: | |
${collection.data().description} | |
${stories | |
.filter( | |
(story) => | |
storyIdToAssessments.size === 0 || |
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
/** | |
* @param {number[]} arr | |
* @param {number} k | |
* @return {number} | |
*/ | |
var maxSumAfterPartitioning = function(arr, k) { | |
// [10,9,3,2] | |
// k = 2 | |
// 30 | |
// [[10], [9, 3], [2]] |
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
int pairedVal = values.front(); | |
int maxScore = 0; | |
for (int i = 1; i < values.size(); ++i) { | |
maxScore = max(values[i] + --pairedVal, maxScore); | |
pairedVal = max(values[i], pairedVal); | |
} | |
return maxScore; |