- DP for beginners by @wh0ami - https://leetcode.com/discuss/general-discussion/662866/dp-for-beginners-problems-patterns-sample-solutions || [LIST - https://leetcode.com/list/x1k8lxi5]
- Graph for beginners by @wh0ami - https://leetcode.com/discuss/general-discussion/655708/graph-for-beginners-problems-pattern-sample-solutions/562734 || [LIST - https://leetcode.com/list/x1wy4de7]
- Sliding window for beginners by @wh0ami - https://leetcode.com/discuss/general-discussion/657507/sliding-window-for-beginners-problems-template-sample-solutions/562721 || [LIST - https://leetcode.com/list/x1lbzfk3]
- DP Patterns by @aatalyk - https://leetcode.com/discuss/general-discussion/458695/dynamic-programming-patterns Leetcode patterns from edu_cative_dot_io by @late_riser - https://leetcode.com/discuss/general-discussion/457546/LeetCode-Problem-Patterns-from-***
- List of questions sorted by common patterns by @Maverick2594 - https://leetcode.com/discuss/career/448285/List-of-q
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
''' | |
9 9 | |
[(0, 0, 3), (0, 2, 5), (0, 2, 7)] | |
3 | |
''' | |
def google_count_sqr(M): | |
"""[summary] | |
XXX: Calculate cumulative sums by rows and by columns | |
Then loop all left-upper corner and possible square len to check ALL-4 side len |
- Collections of useful short cmd/scripts to do boring jobs.
- Repace spaces in file names : https://stackoverflow.com/questions/1806868/linux-replacing-spaces-in-the-file-names
for file in *; do mv "$file" `echo $file | tr ' ' '_'` ; done
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 | |
export PW=`cat password` | |
# Create a self signed key pair root CA certificate. | |
keytool -genkeypair -v \ | |
-alias rootca \ | |
-dname "CN=rootca, OU=Example Org, O=Example Company, L=San Francisco, ST=California, C=US" \ | |
-keystore rootca.jks \ | |
-keypass:env PW \ |
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
# https://cloud.google.com/iot/docs/how-tos/credentials/keys | |
openssl req -x509 -nodes -newkey rsa:2048 -keyout rsa_private.pem \ | |
-days 1000000 -out rsa_cert.pem -subj "/CN=unused" | |
# This command generate certificate with private key, so I can build jwt in jwt.io. | |
# Also, I can use the certificate(x5c) as publicKey in JWKS for testing. |
- learn deadlock: You are the Scheduler
- Overthewire: We're hackers, and we are good-looking. We are the 1%.
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
Making install in monitoring | |
make[2]: Entering directory '/home/p1/openmpi-3.0.1/test/monitoring' | |
make[3]: Entering directory '/home/p1/openmpi-3.0.1/test/monitoring' | |
make[3]: Nothing to be done for 'install-data-am'. | |
/bin/mkdir -p '/usr/local/lib' | |
/bin/bash ../../libtool --mode=install /usr/bin/install -c monitoring_prof.la '/usr/local/lib' | |
libtool: warning: relinking 'monitoring_prof.la' | |
libtool: install: (cd /home/p1/openmpi-3.0.1/test/monitoring; /bin/bash "/home/p1/openmpi-3.0.1/libtool" --silent --tag CC --mode=relink gcc -O3 -DNDEBUG -finline-functions -fno-strict-aliasing -pthread -module -avoid-version -shared -o monitoring_prof.la -rpath /usr/local/lib monitoring_prof.lo ../../ompi/libmpi.la ../../opal/libopen-pal.la -lrt -lm -lutil -lz ) | |
libtool: install: /usr/bin/install -c .libs/monitoring_prof.soT /usr/local/lib/monitoring_prof.so | |
libtool: install: /usr/bin/install -c .libs/monitoring_prof.lai /usr/local/lib/monitoring_prof.la |
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
# Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*) | |
# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/ | |
# Example format: plugins=(rails git textmate ruby lighthouse) | |
# Add wisely, as too many plugins slow down shell startup. | |
plugins=( | |
git | |
pip | |
kubectl completion zsh | |
docker | |
docker-compose |
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
# If you change this file, run 'update-grub' afterwards to update | |
# /boot/grub/grub.cfg. | |
# For full documentation of the options in this file, see: | |
# info -f grub -n 'Simple configuration' | |
GRUB_DEFAULT=0 | |
GRUB_HIDDEN_TIMEOUT=0 | |
GRUB_HIDDEN_TIMEOUT_QUIET=true | |
GRUB_TIMEOUT=10 | |
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian` |
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
130 p1@p1-xos:~⟫ sudo nvidia-docker run -ti -p 8888:8888 bvlc/caffe:gpu /bin/bash | |
root@5842b6adba3a:/workspace# pip install jupyter | |
Collecting jupyter | |
Downloading jupyter-1.0.0-py2.py3-none-any.whl | |
Collecting ipykernel (from jupyter) | |
Downloading ipykernel-4.6.1-py2-none-any.whl (104kB) | |
100% |################################| 112kB 4.0MB/s | |
Collecting jupyter-console (from jupyter) | |
Downloading jupyter_console-5.1.0-py2.py3-none-any.whl | |
Collecting qtconsole (from jupyter) |
NewerOlder