I hereby claim:
- I am yangshun on github.
- I am yangshun (https://keybase.io/yangshun) on keybase.
- I have a public key ASALzkiMtwtQ1tT2loY5YKoN54yysqWWF7TLUB8ai024BAo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
'use strict'; | |
const {useCallback, useState} = require('React'); | |
const nullthrows = require('nullthrows'); | |
type InputValue<T> = {| | |
// Whether the input value has changed since it was initialized. | |
changed: boolean, | |
// A string key to uniquely identify the value. |
#!/bin/bash | |
text="/** | |
* Copyright (c) 2017-present, Facebook, Inc. | |
* | |
* This source code is licensed under the MIT license found in the | |
* LICENSE file in the root directory of this source tree. | |
*/ | |
" |
module.exports = (babel) => { | |
const { types: t } = babel; | |
const GLOBAL_EXPOSURE_IDENTIFIER = 'babelPluginExportPrivates'; | |
const HOIST_PRAGMA = 'babel-plugin-export-privates'; | |
const identifiers = new Set(); | |
function attachToGlobalObject(path, identifierName) { | |
identifiers.add(identifierName); | |
// Attach to global object to be exposed for exporting later. | |
path.insertAfter( |
cd ~/nusmods/www
git pull
yarn && npm run build
let res = ''; | |
$('#question_list tbody tr').each(function () { | |
const $td = $(this).find('td'); | |
const $link = $($td[2]).find('a').first(); | |
res += `[${$($td[1]).text().trim()} - ${$link.text()}](https://leetcode.com${$link.attr('href')})\n`; | |
}); | |
console.log(res); |
# Place the ffmpeg binary in the same directory. | |
for video_file in *.mp4 | |
do | |
audio_file="${video_file/.mp4/.mp3}" | |
if [ -f "$audio_file" ]; then | |
echo "$audio_file exists." | |
else | |
echo "Converting $video_file to $audio_file." | |
./ffmpeg -i "$video_file" -vn -sn -c:a mp3 -ab 192k "$audio_file" | |
fi |
Would advise you all to practice just for fun. I know a lot of students don't get much practice for interviews.